PEAR is discontinued

This is a static archive preserving historical releases and metadata. No new packages or updates will be published. For updates to existing packages, or to publish new packages, please use Composer and Packagist.

Home » PEAR » PEAR » Bug #2070

leading slash in ptmp var causes install to fail

Details

Submitted2004-08-05 20:17 UTC
Fromedgester at yahoo dot com
Assignedcellog
StatusClosed
PackagePEAR
PHP Version4.3.2
OSWindows 2000
Roadmaps(Not assigned)

Comments

[2004-08-05 20:17 UTC] edgester at yahoo dot com

Description:
------------
When installing pear using a web browsers under windows 2000 with the WAMPP2 apache install, i got an error message during the install.

paraphrased: Cannot fopen Archive/Tar.php Require failed php_include=/C:/some/directory...

The laeading slash in the inlude path is the problem. $ptmp must be fixed.

go-pear.php downloaded from go-pear.org today (Aug 5, 2004)

Reproduce code:
---------------
The following code will fix the $ptmp variable.

---------<cut>----------------
$ptmp=preg_replace("|^/|", "", $ptmp);
---------<cut>---------------

I inserted it at line 392, but it should probably go before line 390 just inside the "if (WINDOWS)" code block in the "Temp Stuff"-commented section.

The fix should be applied on win2k platforms (or all windows platforms) before the $ptmp variable is used.