diff --git a/nselib/unpwdb.lua b/nselib/unpwdb.lua index 3452639f4..a2f554c54 100644 --- a/nselib/unpwdb.lua +++ b/nselib/unpwdb.lua @@ -111,8 +111,8 @@ local filltable = function(filename, table) for l in file:lines() do -- Comments takes up a whole line - if not l:match("#!comment:") then - table[#table + 1] = l + if not l:match("^#!comment:") then + table[#table + 1] = l:gsub("[\r\n]+$", "") end end