Re[2]: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_default_classes.c zend_default_classes.h
| From: | Andi Gutmans | Date: | Sat, 30 Aug 2003 19:33:08 +0000 |
| Subject: | Re[2]: [ZEND-ENGINE-CVS] cvs: ZendEngine2 / zend_default_classes.c zend_default_classes.h | ||
| References: | 1 2 | Groups: | php.zend-engine.cvs |
| Request: | Send a blank email to php-zend-engine-cvs+get-1755@lists.php.net to get a copy of this message | ||
At 09:18 PM 8/30/2003 +0200, Marcus Börger wrote:
Hello Andi, Saturday, August 30, 2003, 9:01:26 PM, you wrote: AG> Marcus, AG> You shouldn't use malloc()/free() if possible during execution. I suggest AG> you either use emalloc()/efree() or if you want to allocate on the stack AG> then use do_alloca()/free_alloca(). The real problem here is that we don't detect C99 compliant snprintf in Zend and can't move spprintf into Zend engine. So i did the best compromise available.Isn't always using the vsnprintf() an option even when it's _GNU_SOURCE? It's maybe not optimal because you have to use an arbitrary limit but it's OK for now. I can't remember if the versions in PHP's source tree use emalloc() or not. If they do we could possibly use it. Andi