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

 ID:                 53414
 Updated by:         [email protected]
 Reported by:        mv28jam at gmail dot com
 Summary:            autoload problem in class destructor
-Status:             Open
+Status:             Bogus
 Type:               Bug
 Package:            Class/Object related
 Operating System:   WindowsXP/Linux Fedora
 PHP Version:        5.2.14
 Block user comment: N
 Private report:     N

 New Comment:

Thank you for taking the time to write to us, but this is not
a bug. Please double-check the documentation available at
http://www.php.net/manual/ and the instructions on how to report
a bug at http://bugs.php.net/how-to-report.php

Some SAPIs change the working directory before starting the shutdown.
Nothing we can change.


Previous Comments:
------------------------------------------------------------------------
[2010-11-26 14:29:54] mv28jam at gmail dot com

rename

------------------------------------------------------------------------
[2010-11-26 14:29:51] mv28jam at gmail dot com

rename

------------------------------------------------------------------------
[2010-11-26 14:27:19] mv28jam at gmail dot com

Description:
------------
__autoload does not works in class destructor when path in autoload is
relative

Test script:
---------------
function __autoload($class_name){

        $res=include_once('./'.$class_name.'.class.php');

}

class Test1{

        public function __destruct(){

                $obj = new Test2;

        }

}

$test= new Test1;



//other file

class Test2{}

Expected result:
----------------
class autoload

Actual result:
--------------
on windows



Warning: include_once(./Test2.class.php) [function.include-once]: failed
to open stream: No such file or directory in
C:\VertrigoServ\www\index.php on line 3



same on Fedora


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



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

Reply via email to