Changeset

4143:eccd3c87d717

net.httpserver: Log when an error occurs inside a HTTP request handler
author Matthew Wild <mwild1@gmail.com>
date Sun, 13 Feb 2011 22:57:17 +0000
parents 4136:19f2830fbe02
children 4144:a1ff207af280 4147:7f119ebcf55f 4168:4919831b5b56
files net/httpserver.lua
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/net/httpserver.lua	Thu Feb 03 13:13:49 2011 +0500
+++ b/net/httpserver.lua	Sun Feb 13 22:57:17 2011 +0000
@@ -122,6 +122,7 @@
 			call_callback(request);
 		end
 		local function error_cb(r)
+			log("error", "Error in HTTP server handler: %s", r or "connection-closed");
 			call_callback(request, r or "connection-closed");
 			destroy_request(request);
 		end