PHP 4.0 Bug #3698 Updated: Segfault w/ classes

From: Date: Fri, 03 Mar 2000 14:15:58 +0000
Subject: PHP 4.0 Bug #3698 Updated: Segfault w/ classes
Groups: php.dev 
Request: Send a blank email to php-dev+get-16343@lists.php.net to get a copy of this message
ID: 3698 User Update by: johan@ekenberg.nu Status: Analyzed Bug Type: Reproduceable crash Description: Segfault w/ classes I did not realize that a subclass without a constructor of its own would call upon the constructor of its parent. Call me stupid, but I actually misunderstood the PHP documentation on this point. From a userland point of view, the obvious fix is to include an empty constuctor in Second_class, like this: class Second_class extends Base_class { function Second_class() { // absolutely empty, just stopping // Base_class constructor from being called. } } From a developer point of view the task still remains, to detect and stop this kind of endless loops from crashing apache. I'm sorry, I can't help you there... Thanks a lot to everybody involved! /Johan Ekenberg Full Bug description available at: http://bugs.php.net/version4/?id=3698

« previous php.dev (#16343) next »