cvs: ZendEngine2(PHP_5_3) / zend_alloc.c

From: Date: Mon, 21 Jul 2008 17:06:36 +0000
Subject: cvs: ZendEngine2(PHP_5_3) / zend_alloc.c
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-6907@lists.php.net to get a copy of this message
dmitry Mon Jul 21 17:06:36 2008 UTC Modified files: (Branch: PHP_5_3) /ZendEngine2 zend_alloc.c Log: Added check for small ZEMD_MM_SEG_SIZE http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_alloc.c?r1=1.144.2.3.2.43.2.12&r2=1.144.2.3.2.43.2.13&diff_format=u Index: ZendEngine2/zend_alloc.c diff -u ZendEngine2/zend_alloc.c:1.144.2.3.2.43.2.12 ZendEngine2/zend_alloc.c:1.144.2.3.2.43.2.13 --- ZendEngine2/zend_alloc.c:1.144.2.3.2.43.2.12 Sun May 11 11:46:44 2008 +++ ZendEngine2/zend_alloc.c Mon Jul 21 17:06:35 2008 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_alloc.c,v 1.144.2.3.2.43.2.12 2008/05/11 11:46:44 mattwil Exp $ */ +/* $Id: zend_alloc.c,v 1.144.2.3.2.43.2.13 2008/07/21 17:06:35 dmitry Exp $ */ #include "zend.h" #include "zend_alloc.h" @@ -1125,6 +1125,9 @@ if (zend_mm_low_bit(seg_size) != zend_mm_high_bit(seg_size)) { fprintf(stderr, "ZEND_MM_SEG_SIZE must be a power of two\n"); exit(255); + } else if (seg_size < ZEND_MM_ALIGNED_SEGMENT_SIZE + ZEND_MM_ALIGNED_HEADER_SIZE) { + fprintf(stderr, "ZEND_MM_SEG_SIZE is too small\n"); + exit(255); } } else { seg_size = ZEND_MM_SEG_SIZE;

« previous php.zend-engine.cvs (#6907) next »