cvs: ZendEngine2 / zend_alloc.c zend_alloc.h

From: Date: Thu, 12 Oct 2006 06:47:04 +0000
Subject: cvs: ZendEngine2 / zend_alloc.c zend_alloc.h
Groups: php.zend-engine.cvs 
Request: Send a blank email to php-zend-engine-cvs+get-5323@lists.php.net to get a copy of this message
dmitry Thu Oct 12 06:47:04 2006 UTC Modified files: /ZendEngine2 zend_alloc.c zend_alloc.h Log: Make zend_memory_peak_usage() to be avalable even without --enable-memory-limit http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_alloc.c?r1=1.162&r2=1.163&diff_format=u Index: ZendEngine2/zend_alloc.c diff -u ZendEngine2/zend_alloc.c:1.162 ZendEngine2/zend_alloc.c:1.163 --- ZendEngine2/zend_alloc.c:1.162 Sat Sep 30 17:17:31 2006 +++ ZendEngine2/zend_alloc.c Thu Oct 12 06:47:04 2006 @@ -18,7 +18,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_alloc.c,v 1.162 2006/09/30 17:17:31 iliaa Exp $ */ +/* $Id: zend_alloc.c,v 1.163 2006/10/12 06:47:04 dmitry Exp $ */ #include "zend.h" #include "zend_alloc.h" @@ -1850,16 +1850,18 @@ } } -#if MEMORY_LIMIT ZEND_API size_t zend_memory_peak_usage(int real_usage TSRMLS_DC) { +#if MEMORY_LIMIT if (real_usage) { return AG(mm_heap)->real_peak; } else { return AG(mm_heap)->peak; } -} +#else + return 0; #endif +} ZEND_API void shutdown_memory_manager(int silent, int full_shutdown TSRMLS_DC) http://cvs.php.net/viewvc.cgi/ZendEngine2/zend_alloc.h?r1=1.75&r2=1.76&diff_format=u Index: ZendEngine2/zend_alloc.h diff -u ZendEngine2/zend_alloc.h:1.75 ZendEngine2/zend_alloc.h:1.76 --- ZendEngine2/zend_alloc.h:1.75 Thu Oct 5 08:09:12 2006 +++ ZendEngine2/zend_alloc.h Thu Oct 12 06:47:04 2006 @@ -17,7 +17,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: zend_alloc.h,v 1.75 2006/10/05 08:09:12 dmitry Exp $ */ +/* $Id: zend_alloc.h,v 1.76 2006/10/12 06:47:04 dmitry Exp $ */ #ifndef ZEND_ALLOC_H #define ZEND_ALLOC_H @@ -119,10 +119,8 @@ #define full_mem_check(silent) #endif -#if MEMORY_LIMIT ZEND_API size_t zend_memory_usage(int real_usage TSRMLS_DC); ZEND_API size_t zend_memory_peak_usage(int real_usage TSRMLS_DC); -#endif END_EXTERN_C()

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