ID:               23038
 Updated by:       [EMAIL PROTECTED]
 Reported By:      black at sunshine dot krneki dot org
-Status:           Assigned
+Status:           Closed
 Bug Type:         Scripting Engine problem
 Operating System: linux debian
 PHP Version:      4.3.2-RC
 Assigned To:      andrei
 New Comment:

This bug has been fixed in CVS.

In case this was a PHP problem, snapshots of the sources are packaged
every three hours; this change will be in the next snapshot. You can
grab the snapshot at http://snaps.php.net/.
 
In case this was a documentation problem, the fix will show up soon at
http://www.php.net/manual/.

In case this was a PHP.net website problem, the change will show
up on the PHP.net site and on the mirror sites in short time.
 
Thank you for the report, and for helping us make PHP better.




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

[2003-05-23 11:14:44] hewei at ied dot org dot cn

This short script can reproduce the aggregation bug I reported above.

class bar {
 
   function doit()
   {
      print " Doing...\n";
   }
}


class foo {

   function foo()
   {
       print_r(aggregation_info($this));
       aggregate($this, "bar");
   }
   
   function spawn()
   {
       return new foo();
   }
}

$a = new foo();
$a->doit();
$b = $a->spawn();
$b->doit();
unset($a);
$c = $b->spawn();
$c->doit();

Besides 'unset($a)', '$a = new foo()' will also cause the same problem.

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

[2003-05-01 01:31:02] hewei at ied dot org dot cn

Similar problem happens to me. I either cannot reproduce the
situation because sometimes changing a irrelevant place will temporaily
wipe the problem away. But it will come back at an unexpected time.

The problem once caused Apache 2.0 crashing on Win32. But after some
irrelevant code restructuring, it now casues
error like this:

Fatal error: Call to undefined function: foo() in /path/bar.php on line
xxx

But foo() is surely an aggregated method. The strange but perhaps
useful point is that a print_r of aggregation_info() at the bug place
shows the function dose exists. Even I add the following codes the
error still exists:

if (!method_exists($this, "foo")) {
    deaggregate($this, "CLASS_having_method_foo");
    aggregate($this, "CLASS_having_method_foo");
}

This problem really stops me from doing any futher coding.
I tried ZendSafeGard, upgraded to the 4.3.2RC2, changed from Apache
module to CGI, and moved from Windows to Linux(RedHat 9.0). But none
seems to imporve the situation.

Since the problem is not easily reproduced outside my complex class
hierarchy, please instruct me of any other debug information I can
print out at the bug place. And because the PHP I'm using is
recompiled, I would even like to try do source codes debugging.

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

[2003-04-06 16:22:40] [EMAIL PROTECTED]

just letting you know that its been a week now with not a single crash

after removing aggregate - contact me when/if you want/need the db 
dump and code dump to analyze this/test it. 

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

[2003-04-03 19:45:12] [EMAIL PROTECTED]

.


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

[2003-04-03 15:38:50] [EMAIL PROTECTED]

according to http://snaps.php.net there is? 
 
and yeah, i guess you could mark it as bogus, as far as "simple" 
scripts go, i doubt i could ever reproduce this in a simple one.. even

the collection of code i use has about 170k just core files (and its 
clean non bloated code if you believe it ;)).. 
 
the best i can do is give you a cvs snapshot of a week ago when the 
bug was still occuring.. after i removed aggregate i havent had a 
crash.. 
 
as for my debugging knowledge goes, its pretty much what i gathered 
from this page, and you cant really expect me to master gdb and 
valgrind without experience with any of them before. 
 
if you want to give it a shot then by all means, im willing to give you

everything that is in my power to do so, a short example script 
however, is not. 

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

The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
    http://bugs.php.net/23038

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

Reply via email to