cvs: php-src(PHP_4_3) /main rfc1867.c

From: Date: Wed, 12 Nov 2003 22:34:35 +0000
Subject: cvs: php-src(PHP_4_3) /main rfc1867.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-24504@lists.php.net to get a copy of this message
sesser Wed Nov 12 17:34:35 2003 EDT Modified files: (Branch: PHP_4_3) /php-src/main rfc1867.c Log: Fix odd increments to repair the boundary checks. Index: php-src/main/rfc1867.c diff -u php-src/main/rfc1867.c:1.122.2.15 php-src/main/rfc1867.c:1.122.2.16 --- php-src/main/rfc1867.c:1.122.2.15 Thu Nov 6 10:41:37 2003 +++ php-src/main/rfc1867.c Wed Nov 12 17:34:34 2003 @@ -16,7 +16,7 @@ | Jani Taskinen <sniper@php.net> | +----------------------------------------------------------------------+ */ -/* $Id: rfc1867.c,v 1.122.2.15 2003/11/06 15:41:37 hirokawa Exp $ */ +/* $Id: rfc1867.c,v 1.122.2.16 2003/11/12 22:34:34 sesser Exp $ */ /* * This product includes software developed by the Apache Group @@ -72,6 +72,10 @@ void php_mb_gpc_realloc_buffer(char ***pval_list, int **plen_list, int *num_vars_max, int inc TSRMLS_DC) { + /* allow only even increments */ + if (inc & 1) { + inc++; + } (*num_vars_max) += inc; *pval_list = (char **)erealloc(*pval_list, (*num_vars_max+2)*sizeof(char *)); *plen_list = (int *)erealloc(*plen_list, (*num_vars_max+2)*sizeof(int));

« previous php.cvs (#24504) next »