Hi Olivier,

Em Qua, 2008-10-15 às 15:44 +0200, Olivier Bonvalet escreveu:
> So, I reduce the script which throw the segmentation fault.
> 
> My environment :
>     Debian Lenny, 64bits
>     Latest PHP 5.2 from CVS (php5.2-200810151030) compiled with :
>         ./configure --prefix=/home/dev-olivier/usr/ --disable-all 
> --enable-debug
> 
> 
> In "first.php" I have this code :
> ============================================================
> <?php
> class main
> {
>     public static $dummy        = NULL ;
>     public static $dataAccessor = NULL ;
> }
> 
> class dataAccessor
> {
> }
> 
> class relay
> {
>     public function __get( $name )
>     {
>         main::$dataAccessor = new dataAccessor;
>     }
> }
> 
> class dummy
> {
> }
> 
> main::$dummy        = new dummy();
> main::$dataAccessor = new relay();
> ?>
> ============================================================
> 
> And in "second.php" I have this :
> (if I regroup all code in one file, there is no segfault)

That is weird, cannot you reproduce it using the code below?

<?php
class main
{
    public static $dataAccessor;
}

class relay
{
    public function __get($name)
    {
                main::$dataAccessor = 1;
    }
}

main::$dataAccessor = new relay();
var_dump(main::$dataAccessor->bar);

?>

Anyway, please file a bug report: http://bugs.php.net/report.php

Thanks.

-- 
Regards,
Felipe Pena


-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to