aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--networking/httpd.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/networking/httpd.c b/networking/httpd.c
index 70a024bc2..63c17556f 100644
--- a/networking/httpd.c
+++ b/networking/httpd.c
@@ -1008,7 +1008,7 @@ static int sendHeaders(HttpResponseNum responseNum)
1008 /* emit the current date */ 1008 /* emit the current date */
1009 strftime(timeStr, sizeof(timeStr), RFC1123FMT, gmtime(&timer)); 1009 strftime(timeStr, sizeof(timeStr), RFC1123FMT, gmtime(&timer));
1010 len = sprintf(buf, 1010 len = sprintf(buf,
1011 "HTTP/1.0 %d %s\nContent-type: %s\r\n" 1011 "HTTP/1.0 %d %s\r\nContent-type: %s\r\n"
1012 "Date: %s\r\nConnection: close\r\n", 1012 "Date: %s\r\nConnection: close\r\n",
1013 responseNum, responseString, mime_type, timeStr); 1013 responseNum, responseString, mime_type, timeStr);
1014 1014
@@ -1325,11 +1325,11 @@ static int sendCgi(const char *url,
1325 if (firstLine) { 1325 if (firstLine) {
1326 rbuf[count] = 0; 1326 rbuf[count] = 0;
1327 /* check to see if the user script added headers */ 1327 /* check to see if the user script added headers */
1328 if(strncmp(rbuf, "HTTP/1.0 200 OK\n", 4) != 0) { 1328 if(strncmp(rbuf, "HTTP/1.0 200 OK\r\n", 4) != 0) {
1329 bb_full_write(s, "HTTP/1.0 200 OK\n", 16); 1329 bb_full_write(s, "HTTP/1.0 200 OK\r\n", 17);
1330 } 1330 }
1331 if (strstr(rbuf, "ontent-") == 0) { 1331 if (strstr(rbuf, "ontent-") == 0) {
1332 bb_full_write(s, "Content-type: text/plain\n\n", 26); 1332 bb_full_write(s, "Content-type: text/plain\r\n\r\n", 28);
1333 } 1333 }
1334 firstLine = 0; 1334 firstLine = 0;
1335 } 1335 }