aboutsummaryrefslogtreecommitdiff
path: root/busybox/networking/httpd.c
diff options
context:
space:
mode:
Diffstat (limited to 'busybox/networking/httpd.c')
-rw-r--r--busybox/networking/httpd.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/busybox/networking/httpd.c b/busybox/networking/httpd.c
index 94fcfc8c1..e3f4027dc 100644
--- a/busybox/networking/httpd.c
+++ b/busybox/networking/httpd.c
@@ -1259,6 +1259,8 @@ static int sendCgi(const char *url,
1259 post_readed_idx += count; 1259 post_readed_idx += count;
1260 if(post_readed_size == 0) 1260 if(post_readed_size == 0)
1261 post_readed_idx = 0; 1261 post_readed_idx = 0;
1262 } else {
1263 post_readed_size = post_readed_idx = bodyLen = 0; /* broken pipe to CGI */
1262 } 1264 }
1263 } else if(bodyLen > 0 && post_readed_size == 0 && FD_ISSET(a_c_r, &readSet)) { 1265 } else if(bodyLen > 0 && post_readed_size == 0 && FD_ISSET(a_c_r, &readSet)) {
1264 count = bodyLen > sizeof(wbuf) ? sizeof(wbuf) : bodyLen; 1266 count = bodyLen > sizeof(wbuf) ? sizeof(wbuf) : bodyLen;
@@ -1266,7 +1268,7 @@ static int sendCgi(const char *url,
1266 if(count > 0) { 1268 if(count > 0) {
1267 post_readed_size += count; 1269 post_readed_size += count;
1268 bodyLen -= count; 1270 bodyLen -= count;
1269 } else { 1271 } else {
1270 bodyLen = 0; /* closed */ 1272 bodyLen = 0; /* closed */
1271 } 1273 }
1272 } 1274 }