File:  [ELWIX - Embedded LightWeight unIX -] / embedaddon / php / ext / session / tests / bug53141.phpt
Revision 1.1.1.1 (vendor branch): download - view: text, annotated - select for diffs - revision graph
Tue Feb 21 23:48:01 2012 UTC (12 years, 4 months ago) by misho
Branches: php, MAIN
CVS tags: v5_4_3elwix, v5_4_29p0, v5_4_29, v5_4_20p0, v5_4_20, v5_4_17p0, v5_4_17, v5_3_10, HEAD
php

    1: --TEST--
    2: Bug #53141 (autoload misbehaves if called from closing session)
    3: --SKIPIF--
    4: <?php include('skipif.inc'); ?>
    5: --FILE--
    6: <?php
    7: spl_autoload_register(function ($class) {
    8:     var_dump("Loading $class");
    9:     eval('class Bar {}');
   10: });
   11: 
   12: class Foo
   13: {
   14:     function __sleep()
   15:     {
   16:         new Bar;
   17:         return array();
   18:     }
   19: }
   20: 
   21: session_start();
   22: $_SESSION['foo'] = new Foo;
   23: 
   24: ?>
   25: --EXPECT--
   26: string(11) "Loading Bar"

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>