Re: Re: PEAR-Installation with go-pear

From: Date: Mon, 02 Dec 2002 09:22:33 +0000
Subject: Re: Re: PEAR-Installation with go-pear
References: 1 2  Groups: php.pear.general 
Request: Send a blank email to pear-general+get-2883@lists.php.net to get a copy of this message
On Sun, Dec 01, 2002 at 05:45:25PM +0100, Christian Dickmann wrote: > > Warning: OpenDir: Invalid argument (errno 22) in g:\webroot\go-pear.php on > > line 784 [...] > > 314 $ptmp = tempnam(tmp_dir(), 'gope'); print "Temp Stuff $ptmp\n"; > > 315 rm_rf($ptmp); print "rm_rf $ptmp\n"; > > 316 mkdir_p($ptmp, 0700); If (mkdir_p){print "Directory $ptmp\n";}; > > 317 > > 318 $ok = @chdir($ptmp);{print "Directory ok? $ok\n";}; sleep(30); > > 783 if (@is_dir($path)) { print "The path for opendir: $path"; > > 784 $dp = opendir($path); > > Whats wrong? > > I really don't know! > I think its a permission issue. I will try to debug it, my that might need > some time :( I do not know if this is the problem on Windows, but it is not good idea running go-pear under Unix in safe-mode enabled. I have checked that mkdir_p would not make directory in safe mode because of PHP "mkdir" bug. It was reported to bugs.php.net, and is fixed in cvs (would be in php 4.3). The problem is because mkdir($variable, ...) change $variable to parent($variable). As I said the problem with mkdir() in safe mode should gone in php 4.3. To workaround this bug go-pear need to change mkdir() call in mkdir_p() from: $ok = @mkdir($dir, $mode); to: $ok = @mkdir("$dir", $mode); Because "Directory $ptmp\n" prints unchanged $ptmp variable (line 316) I think that errno 22 would mean that directory is in "read only" mode. I have found on google php bug report on that: http://bugs.php.net/bug.php?id=12699 Best regards, -- Piotr Klaban

« previous php.pear.general (#2883) next »