properly terminate POST requests
authorFelix Fietkau <nbd@openwrt.org>
Sat, 29 Mar 2014 19:17:46 +0000 (20:17 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 29 Mar 2014 19:17:46 +0000 (20:17 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
uclient-http.c

index 1ab1f4619c5dd52820b1e0b928be97ef2e2cf49b..2005f0cd0cf5ba9e6c58ab3ef800daccb1cbf26e 100644 (file)
@@ -850,6 +850,8 @@ uclient_http_request_done(struct uclient *cl)
                return -1;
 
        uclient_http_send_headers(uh);
+       if (uh->req_type == REQ_POST)
+               ustream_printf(uh->us, "0\r\n\r\n");
        uh->state = HTTP_STATE_REQUEST_DONE;
 
        return 0;