From 34913291ddb25075bb0fc73744e9c2e30754d427 Mon Sep 17 00:00:00 2001 From: jow Date: Thu, 9 Sep 2010 20:16:00 +0000 Subject: [PATCH] [backfire] merge r22988 git-svn-id: svn://svn.openwrt.org/openwrt/branches/backfire@22989 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- package/uhttpd/Makefile | 2 +- package/uhttpd/src/uhttpd.c | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/package/uhttpd/Makefile b/package/uhttpd/Makefile index 086c29458..e37fa90ec 100644 --- a/package/uhttpd/Makefile +++ b/package/uhttpd/Makefile @@ -8,7 +8,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=uhttpd -PKG_RELEASE:=17 +PKG_RELEASE:=18 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME) PKG_BUILD_DEPENDS := libcyassl liblua diff --git a/package/uhttpd/src/uhttpd.c b/package/uhttpd/src/uhttpd.c index 6f5e61634..a818e1c45 100644 --- a/package/uhttpd/src/uhttpd.c +++ b/package/uhttpd/src/uhttpd.c @@ -401,6 +401,10 @@ static struct http_request * uh_http_header_recv(struct client *cl) { ensure_out(rlen = uh_tcp_recv(cl, bufptr, rlen)); + /* unexpected eof - #7904 */ + if( rlen == 0 ) + return NULL; + blen -= rlen; bufptr += rlen; }