|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #64243 Fatal error: Allowed memory size on very simple script
Submitted: 2013-02-19 07:30 UTC Modified: 2015-08-03 21:32 UTC
Avg. Score:4.8 ± 0.4
Reproduced:4 of 4 (100.0%)
Same Version:1 (25.0%)
Same OS:1 (25.0%)
From: bastiaan at basenlily dot me Assigned: cmb (profile)
Status: Not a bug Package: bcompiler (PECL)
PHP Version: 5.4.11 OS: Mac OS X
Private report: No CVE-ID: None
 [2013-02-19 07:30 UTC] bastiaan at basenlily dot me

I'm trying my hand at getting bcompiler 1.0.2 to work on my Mac OS X 10.8 box 
with PHP 5.4.11

Grabbing the 1.0.2 source and compiling it gives me a number of errors that are 
discussed before and probably related to bcompiler not being compatible with 
5.4. As a result I applied this patch:

I had to make one more small change because for some reason the compiler is 
having issues with the inline function bcompiler_set_stdsize before it would 
I've uploaded the source code as I compile it on github:

I'm trying to compile the script in the test script with the code in the test 
script and end up with:

Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 
1818585089 bytes) in /Projects/web/test/hello world.php on line 15

Test script:
-- File I'm trying to compile: also.php
  class hello {
    public function helloalso() {
      echo 'Hello also<br>';

-- Code I use to compile:
$fh = fopen("also.phb", "w");
bcompiler_write_file($fh, "also.php");

-- and what makes it fail:
include "also.phb";

Expected result:
For also.phb to be loaded properly and be able to instantiate an instance of the 
class hello and call its functions

Actual result:
Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 
1818585089 bytes) in /Projects/web/test/hello world.php on line 15


Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2015-08-03 21:32 UTC]
-Status: Open +Status: Not a bug -Assigned To: +Assigned To: cmb
 [2015-08-03 21:32 UTC]
The author of the patch of bug #60618 already noted: "Please
ignore the patch - it does not work". The bug you're reporting is
most likely caused by the faulty patch, so I'm closing this

If you're interesting in taking over the maintainance of
bcompiler, see <>.
PHP Copyright © 2001-2022 The PHP Group
All rights reserved.
Last updated: Tue Jan 25 09:03:34 2022 UTC