1
0
mirror of https://github.com/nmap/nmap.git synced 2025-12-06 04:31:29 +00:00

Use better construction for iterating lines.

This commit is contained in:
batrick
2010-12-08 14:18:45 +00:00
parent bfa052c2f3
commit 86993d74d5

View File

@@ -246,9 +246,7 @@ function read_from_file( file )
end
local line, ret = nil, {}
while true do
line = f:read()
if not line then break end
for l in f:lines() do
ret[#ret+1] = line
end