unbreak cgis with custom headers on busybox httpd
[openwrt-10.03/.git] / package / busybox / patches / 410-httpd_cgi_headers.patch
1 --- busybox.old/networking/httpd.c      2007-01-19 22:22:59.000000000 +0100
2 +++ busybox.dev/networking/httpd.c      2007-02-01 17:00:56.000000000 +0100
3 @@ -1224,7 +1224,7 @@
4                                  * "chopped up into small chunks" syndrome here */
5                                 rbuf[count] = '\0';
6                                 /* check to see if the user script added headers */
7 -#define HTTP_200 "HTTP/1.0 200 OK\r\n\r\n"
8 +#define HTTP_200 "HTTP/1.0 200 OK\r\n"
9                                 if (memcmp(rbuf, HTTP_200, 4) != 0) {
10                                         /* there is no "HTTP", do it ourself */
11                                         full_write(s, HTTP_200, sizeof(HTTP_200)-1);