From: Glenn L McGrath Date: Mon, 8 Dec 2003 20:21:53 +0000 (-0000) Subject: Stop sending data to the client after the first failure. X-Git-Tag: 1_00_pre4~10 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=9adcf73152e1cb4d537d3ff713abe9d1c51171dd;p=platform%2Fupstream%2Fbusybox.git Stop sending data to the client after the first failure. Patch by Joe.C --- diff --git a/networking/httpd.c b/networking/httpd.c index ba65e13..1a3f5f9 100644 --- a/networking/httpd.c +++ b/networking/httpd.c @@ -1337,7 +1337,8 @@ static int sendFile(const char *url) sendHeaders(HTTP_OK); while ((count = bb_full_read(f, buf, MAX_MEMORY_BUFF)) > 0) { - bb_full_write(a_c_w, buf, count); + if (bb_full_write(a_c_w, buf, count) != count) + break; } close(f); } else {