Re: [OpenWrt-Devel] uhttpd: chunked output from cgi script

2015-10-08 Thread Luigi Tarenga
thank you Jow for the promptly feedback. I tried to better understand the problem and now I'm reading at your commit. My patch works but is logically broken. I'm trying to produce a better one. If I'm not wrong the problem is this (without applying your commit): the client request handling code

Re: [OpenWrt-Devel] uhttpd: chunked output from cgi script

2015-10-08 Thread Jo-Philipp Wich
Hi Luigi, > I tested another patch of mine (really noobish i know :) ) > still against commit: 993cace15114a0f06f720f34a4748ab54b695f0d > [...] > and it seems to works for the reasons I tried to explain in my previous > mail. Right, it will work but emit invalid HTTP responses if a CGI handler

Re: [OpenWrt-Devel] uhttpd: chunked output from cgi script

2015-10-08 Thread Luigi Tarenga
Hi again Jow, I tested another patch of mine (really noobish i know :) ) still against commit: 993cace15114a0f06f720f34a4748ab54b695f0d --- utils.c2015-10-08 15:05:01.209195841 +0200 +++ utils.c2015-10-08 15:04:27.082529799 +0200 @@ -28,10 +28,6 @@ if (cl->request.method ==

Re: [OpenWrt-Devel] uhttpd: chunked output from cgi script

2015-10-07 Thread Jo-Philipp Wich
Hi Luigi, thank you for your patch proposal, it prompted me to take a deeper look into the problem. The issue should be fixed with the following commit: http://nbd.name/gitweb.cgi?p=uhttpd2.git;a=commitdiff;h=7ed2edc40dd6d0171266f3bfbc96466e1d25e3cd Regards, Jow signature.asc Description:

[OpenWrt-Devel] uhttpd: chunked output from cgi script

2015-10-07 Thread Luigi Tarenga
Hello list, I'm working on a CGI written in lua and I'm using uhttpd as webserver on a tp-link AP. I'm using external CGI interpreter, not embedded lua. I need that the output from my CGI is chunked since I would like to avoid to buffer the whole response and calculate the "Content-Length".