mirror of
https://github.com/nmap/nmap.git
synced 2025-12-25 17:09:02 +00:00
use # length operator instead of string.len (canonicalize)
Used this perl command: $ # perl -pi -e 's/string\.len\((.*?)\)/#\1/g' *.nse
This commit is contained in:
@@ -75,7 +75,7 @@ action = function(host, port)
|
||||
|
||||
if title and title ~= "" then
|
||||
result = string.gsub(title , "[\n\r\t]", "")
|
||||
if string.len(title) > 65 then
|
||||
if #title > 65 then
|
||||
stdnse.print_debug("http-title.nse: (%s) Title got truncated!", host.targetname or host.ip );
|
||||
result = string.sub(result, 1, 62) .. "..."
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user