ID:               37831
 Updated by:       [EMAIL PROTECTED]
 Reported By:      joe at estara dot com
-Status:           Closed
+Status:           Bogus
 Bug Type:         Reproducible crash
 Operating System: linux 2.6.16
 PHP Version:      5.1.4


Previous Comments:
------------------------------------------------------------------------

[2006-06-17 04:05:00] joe at estara dot com

rebuilt and it's fixed

------------------------------------------------------------------------

[2006-06-17 03:41:16] joe at estara dot com

Works from the CLI

$ php test.php

PHP Fatal error:  Allowed memory size of 1048576 bytes exhausted (tried
to allocate 804614 bytes) in test.php on line 5

Must be something with apache?

------------------------------------------------------------------------

[2006-06-17 03:32:52] joe at estara dot com

Description:
------------
Using php 5.1.4, --enable-memory-limit appears to have no effect. 

e.g.  php -i: shows I have it set:
memory_limit => 1M => 1M

Configure shows it's in there 

Configure Command =>  './configure' ... '--enable-memory-limit'

Here's the whole thing:
Configure Command =>  './configure' '--prefix=/prod/apache/php'
'--with-apxs2=/p
rod/apache/bin/apxs' '--with-openssl' '--with-mysql=/prod/mysql'
'--with-zlib' '
--without-pear' '--with-gd' '--with-ttf' '--enable-gd-native-ttf'
'--with-freety
pe-dir=/usr' '--with-mcrypt' '--with-imagick=shared'
'--with-pfpro=shared,/prod/
pfpro/' '--enable-sockets' '--with-curl' '--enable-mbstring=all'
'--without-sqli
te' '--without-pdo-sqlite' '--with-jpeg-dir=/usr/'
'--with-png-dir=/usr/' '--wit
h-libdir=lib64' '--enable-memory-limit' '--enable-sysvshm'


Reproduce code:
---------------
<?php
for($i=0;$i<400; $i++) 
  ${'test' . $i}  = file_get_contents("/etc/termcap"); 
?>

Expected result:
----------------
I'd expect it to hit my 1M limit and error out. 

Actual result:
--------------
It uses all available ram on the machine and dies.


------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=37831&edit=1

Reply via email to