PEAR is archived and read-only

This mirror preserves historical PEAR package releases and metadata so existing references remain available.

Home » PEAR » PEAR » Bug #279

magic quotes shouldn't affect PEAR (and all its packages)

Details

Submitted2003-11-20 09:02 UTC
Fromdidou at nexen dot net
Assignedcellog
StatusClosed
PackagePEAR
PHP Version4.3.3
OSLinux/Debian
Roadmaps(Not assigned)

Comments

[2003-11-20 09:02 UTC] didou at nexen dot net

Description:
------------
My php version :
4.3.4 (see #278)

My php.ini line :
magic_quotes_runtime = On

Seems like this line causes problems to PEAR. Actually the problem was located at PEAR/Registry.php:339 where the script tried to unserialize the packages infos when calling PEAR_INFO.

Adding set_magic_quotes_runtime(0); did work.

didou

Reproduce code:
---------------
<?php

// set_magic_quotes_runtime(0);
require 'PEAR/Info.php';
$info = new PEAR_Info('/usr/share/php');
$info->show();

?>

Expected result:
----------------
the Pear info page with all the package listed

Actual result:
--------------
The Pear config and then "An Error occured fetching the package list from the remote server. Please try again."

[2003-11-20 09:04 UTC] didou at nexen dot net

adding error_reporting(E_ALL) shows :

Notice: unserialize(): Error at offset 6 of 8689 bytes in /usr/share/php/PEAR/Registry.php on line 339