aboutsummaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
Diffstat (limited to 'net')
-rw-r--r--net/http/server.lua3
1 files changed, 3 insertions, 0 deletions
diff --git a/net/http/server.lua b/net/http/server.lua
index ac587435..38c54d8c 100644
--- a/net/http/server.lua
+++ b/net/http/server.lua
@@ -236,6 +236,8 @@ function handle_request(conn, request, finish_cb)
request.headers = headers;
request.conn = conn;
+ request.log("debug", "%s %s HTTP/%s", request.method, request.path, request.httpversion);
+
local date_header = os_date('!%a, %d %b %Y %H:%M:%S GMT'); -- FIXME use
local conn_header = request.headers.connection;
conn_header = conn_header and ","..conn_header:gsub("[ \t]", ""):lower().."," or ""
@@ -327,6 +329,7 @@ end
local function prepare_header(response)
local status_line = "HTTP/"..response.request.httpversion.." "..(response.status or codes[response.status_code]);
+ response.log("debug", "%s", status_line);
local headers = response.headers;
local output = { status_line };
for k,v in pairs(headers) do