[package] uhttpd: fix wrongly applied sizeof() leading to writing beyound end of...
authorJo-Philipp Wich <jow@openwrt.org>
Wed, 30 May 2012 15:30:07 +0000 (15:30 +0000)
committerJo-Philipp Wich <jow@openwrt.org>
Wed, 30 May 2012 15:30:07 +0000 (15:30 +0000)
SVN-Revision: 32005

package/uhttpd/Makefile
package/uhttpd/src/uhttpd.c

index f30d6cabd16ba691d6bedff2abb6a0f5c63d3de9..13da14dfe92db5b31116c4dff8cff2a906d9e471 100644 (file)
@@ -8,7 +8,7 @@
 include $(TOPDIR)/rules.mk
 
 PKG_NAME:=uhttpd
-PKG_RELEASE:=33
+PKG_RELEASE:=34
 
 PKG_BUILD_DIR := $(BUILD_DIR)/$(PKG_NAME)
 PKG_CONFIG_DEPENDS := \
index e10f5dc9e164a50e11422d88a41ac8a6d8d0a46f..d5d5dfb982da4e059fbdc6b9d3ab6c0c9575881d 100644 (file)
@@ -385,10 +385,10 @@ static struct http_request * uh_http_header_recv(struct client *cl)
        char *bufptr = cl->httpbuf.buf;
        char *idxptr = NULL;
 
-       ssize_t blen = sizeof(cl->httpbuf)-1;
+       ssize_t blen = sizeof(cl->httpbuf.buf)-1;
        ssize_t rlen = 0;
 
-       memset(bufptr, 0, sizeof(cl->httpbuf));
+       memset(bufptr, 0, sizeof(cl->httpbuf.buf));
 
        while (blen > 0)
        {