local status_line = readline();
local method, path, httpversion = status_line:match("^(%S+)%s+(%S+)%s+HTTP/(%S+)$");
if not method then coroutine.yield("invalid-status-line"); end
- -- TODO parse url
+ path = path:gsub("^//+", "/"); -- TODO parse url more
local headers = readheaders();
-- read body