From cd820ba39b8723bf67f930e4b7474aad4371c1cf Mon Sep 17 00:00:00 2001 From: david Date: Wed, 8 Jul 2009 19:32:40 +0000 Subject: [PATCH] Show the host and port when a script throws an error. --- nse_main.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/nse_main.lua b/nse_main.lua index 90e02837e..2ebeefaea 100644 --- a/nse_main.lua +++ b/nse_main.lua @@ -539,7 +539,8 @@ local function run (threads) local s, result = resume(co, unpack(thread.args, 1, thread.args.n)); if not s then -- script error... hosts[thread.host][co] = nil; - thread:d("%THREAD threw an error!\n%s\n", + thread:d("%THREAD against %s%s threw an error!\n%s\n", + thread.host.ip, thread.port and ":"..thread.port.number or "", traceback(co, tostring(result))); thread:close(); elseif status(co) == "suspended" then