Diff

net/httpserver.lua @ 2275:dd344b94d088

net.httpserver: Fix to work with new server API
author Matthew Wild <mwild1@gmail.com>
date Wed, 02 Dec 2009 18:03:10 +0000
parent 2274:6241da17f48d
child 2321:7e7484a4e821
line wrap: on
line diff
--- a/net/httpserver.lua	Wed Dec 02 18:02:47 2009 +0000
+++ b/net/httpserver.lua	Wed Dec 02 18:03:10 2009 +0000
@@ -216,7 +216,7 @@
 function new_request(handler)
 	return { handler = handler, conn = handler.socket, 
 			write = function (...) return handler:write(...); end, state = "request", 
-			server = http_servers[handler.serverport()],
+			server = http_servers[handler:serverport()],
 			send = send_response,
 			destroy = destroy_request,
 			id = tostring{}:match("%x+$")