Changed memory_get_usage() and memory_get_peak_usage(). Optional boolean argument allows get memory size allocated by emalloc() (by default) or real size of memory allocated from system.

This commit is contained in:
Dmitry Stogov 2006-07-25 13:41:08 +00:00
parent e05efeaff5
commit 61d39cf1c1
7 changed files with 80 additions and 30 deletions

View file

@ -727,7 +727,7 @@ static int send_parsed_php(request_rec * r)
char *mem_usage;
TSRMLS_FETCH();
mem_usage = ap_psprintf(r->pool, "%u", zend_memory_peak_usage(TSRMLS_C));
mem_usage = ap_psprintf(r->pool, "%u", zend_memory_peak_usage(1 TSRMLS_CC));
ap_table_setn(r->notes, "mod_php_memory_usage", mem_usage);
}
#endif