unserialize() and pear

php.internals

Nuno Lopes

21 years ago
Hello, I think that the last unserialize() changes (2004-09-05) have broken it, because now I can't even do a simple 'pear list'. I can reproduce this problem in both my two pcs. Can someone check this problem, please? Thanks, Nuno

Marcus Börger

21 years ago
Hello Nuno, can you sent me he code it is trying to deserialize? marcus Friday, September 10, 2004, 8:42:42 PM, you wrote:
> Hello,
> I think that the last unserialize() changes (2004-09-05) have broken it, > because now I can't even do a simple 'pear list'. > I can reproduce this problem in both my two pcs.
> Can someone check this problem, please?
> Thanks, > Nuno
-- Best regards, Marcus mailto:helly@php.net

Greg Beaver

21 years ago
Nuno: It would also be helpful to know what version of PEAR you are using, and in particular, the setting of magic_quotes_runtime. Earlier PEAR versions choked on the unserialize statements in PEAR_Registry if this setting was on. Greg Marcus Boerger wrote:

Nuno Lopes

21 years ago
Hello Marcus, PHP prints an error for every file in /usr/local/lib/php/.registry One of those files: http://testes.aborla.net/pear.reg prints: "Notice: unserialize(): Error at offset 121 of 8404 bytes in test.php on line 5" Nuno ----- Original Message -----

Greg Beaver

21 years ago
Nuno Lopes wrote:
> Hello Marcus, > > PHP prints an error for every file in /usr/local/lib/php/.registry > One of those files: http://testes.aborla.net/pear.reg > > prints: > "Notice: unserialize(): Error at offset 121 of 8404 bytes in test.php on > line 5"
This file is truncated, please verify that it indeed does not start with a:{ A valid .reg file (for the Cache package) is attached, perhaps you could use it to test unserialize on your end. I suspect something happened and a program ate something from your PEAR installation. Greg

Nuno Lopes

21 years ago
> Nuno Lopes wrote: >> Hello Marcus, >> >> PHP prints an error for every file in /usr/local/lib/php/.registry >> One of those files: http://testes.aborla.net/pear.reg >> >> prints: >> "Notice: unserialize(): Error at offset 121 of 8404 bytes in test.php on >> line 5" > > This file is truncated, please verify that it indeed does not start with > a:{ > > A valid .reg file (for the Cache package) is attached, perhaps you could > use it to test unserialize on your end. I suspect something happened > and a program ate something from your PEAR installation. > > Greg
It doesn't work also with your file: "Notice: unserialize(): Error at offset 26 of 5366 bytes in test2.php on line 4" Nuno

Marcus Börger

21 years ago
Hello Nuno, that should be fixed now. If not report the problem please again here. best regards marcus Saturday, September 11, 2004, 6:17:16 PM, you wrote:
>> Nuno Lopes wrote: >>> Hello Marcus, >>> >>> PHP prints an error for every file in /usr/local/lib/php/.registry >>> One of those files: http://testes.aborla.net/pear.reg >>> >>> prints: >>> "Notice: unserialize(): Error at offset 121 of 8404 bytes in test.php on >>> line 5" >> >> This file is truncated, please verify that it indeed does not start with >> a:{ >> >> A valid .reg file (for the Cache package) is attached, perhaps you could >> use it to test unserialize on your end. I suspect something happened >> and a program ate something from your PEAR installation. >> >> Greg
> It doesn't work also with your file: > "Notice: unserialize(): Error at offset 26 of 5366 bytes in test2.php on > line 4"
> Nuno
-- Best regards, Marcus mailto:helly@php.net

Nuno Lopes

21 years ago
Yes, its fixed. Thanks Marcus! Nuno ----- Original Message -----