Mantis Bugtracker
  

Viewing Issue Advanced Details Jump to Notes ] View Simple ] Issue History ] Print ]
ID Category Severity Reproducibility Date Submitted Last Update
0003823 [Quercus] minor always 12-22-09 09:08 07-13-10 14:54
Reporter domdorn View Status public  
Assigned To
Priority normal Resolution open Platform
Status new   OS
Projection none   OS Version
ETA none Fixed in Version Product Version 4.0.2
  Product Build
Summary 0003823: unserialize not compatible with php unserialize
Description See attached testcase.

tar zxf unserialize_testcase.tar.gz
cd unserialize_testcase
php test.php
-> nothing printed

call test.php with quercus:
/home/domdorn/work/lyrix/branches/quercus/htdocs/unserialize_testcase/test.php:7: Warning: Assertion "" failed [assert] /home/domdorn/work/lyrix/branches/quercus/htdocs/unserialize_testcase/test.php:8: Warning: Assertion "" failed [assert]
Steps To Reproduce
Additional Information
Attached Files  unserialize_testcase.tar.gz [^] (4,568 bytes) 12-22-09 09:08

- Relationships

- Notes
(0004566)
nam
05-11-10 17:02

Can you paste a test case here? Attachments are broken at the moment...
 
(0004618)
sblommers
05-28-10 12:02

Hi, could you paste the test case please, or email to me at sebastiaan.blommers@gmail.com?
 
(0004619)
sblommers
05-28-10 16:21

I tested this using the following code:

<?php
class foo implements Serializable {
    public $bar = "foobar";

    public function unserialize($serialized){
        $array = unserialize($serialized);
        foreach ($array as $name => $values) {
            $this->$name = $values;
        }
    }

    public function serialize(){
        return serialize(get_object_vars($this));
    }
}

$foo = new foo();
$data = serialize($foo);
echo $data;
$foo2 = unserialize($data);
echo $foo2->bar;
?>

On apache2+php5
C:3:"foo":29:{a:1:{s:3:"bar";s:6:"foobar";}}foobar
On Quercus 4.0.8-SNAPSHOT (svn 7166)
O:3:"foo":1:{s:3:"bar";s:6:"foobar";}foobar

Seems incompatible
 

- Issue History
Date Modified Username Field Change
12-22-09 09:08 domdorn New Issue
12-22-09 09:08 domdorn File Added: unserialize_testcase.tar.gz
05-11-10 17:02 nam Note Added: 0004566
05-28-10 12:02 sblommers Note Added: 0004618
05-28-10 16:21 sblommers Note Added: 0004619
05-28-10 16:22 sblommers Issue Monitored: sblommers
07-13-10 14:54 domdorn Severity major => minor


Mantis 1.0.0rc3[^]
Copyright © 2000 - 2005 Mantis Group
36 total queries executed.
29 unique queries executed.
Powered by Mantis Bugtracker