php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #28287 stream_wrapper_register doesn't call __autoload
Submitted: 2004-05-05 17:36 UTC Modified: 2004-05-05 20:20 UTC
From: buri dot peter at trilogic dot hu Assigned:
Status: Closed Package: *General Issues
PHP Version: 5.0.0RC2 OS: Windows XP
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
(description)
Block user comment
Status: Assign to:
Package:
Bug Type:
Summary:
From: buri dot peter at trilogic dot hu
New email:
PHP Version: OS:

 

 [2004-05-05 17:36 UTC] buri dot peter at trilogic dot hu
Description:
------------
stream_wrapper_register does not call the new __autoload function of Zend Engine 2.

Reproduce code:
---------------
VariableStream.class.php:
<?php 
class VariableStream {
    function __call() {}
}
?>

index.php:
<?php
function __autoload( $class ) {
    echo $class;
    include_once( $class . '.class.php' );
}

stream_wrapper_register( 'var', 'VariableStream' );
?>

Expected result:
----------------
VariableStream

Actual result:
--------------
Warning: stream_wrapper_register() [function.stream-wrapper-register]: class 'VariableStream' is undefined in index.php on line 6

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2004-05-05 20:20 UTC] pollita@php.net
This bug has been fixed in CVS.

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/.
 
Thank you for the report, and for helping us make PHP better.

stream_filter_register() got fixed in this patch as well.
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Mar 29 13:01:29 2024 UTC