From f973b4b9f4cec9055a4fedf2de047cd29d20b817 Mon Sep 17 00:00:00 2001 From: dmiller Date: Tue, 15 May 2018 17:00:59 +0000 Subject: [PATCH] Correct an error in the fix for #1211 --- nselib/bittorrent.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nselib/bittorrent.lua b/nselib/bittorrent.lua index c8f1916b7..5806b8e4b 100644 --- a/nselib/bittorrent.lua +++ b/nselib/bittorrent.lua @@ -206,7 +206,7 @@ bdecode = function(buf) pos = pos+1 -- trailing whitespace - elseif string.match(buf, "%s*$", pos) then + elseif string.match(buf, "^%s*$", pos) then pos = len+1 else return nil, "Unknown type found.", pos