#25345 [NEW]: Add touch() after copy()
| From: | phpbugsspam at netebb dot com | Date: | Mon, 01 Sep 2003 19:17:56 +0000 |
| Subject: | #25345 [NEW]: Add touch() after copy() | ||
| Groups: | php.pear.dev | ||
| Request: | Send a blank email to pear-dev+get-20970@lists.php.net to get a copy of this message | ||
From: phpbugsspam at netebb dot com
Operating system: Any
PHP version: 4CVS-2003-09-01 (stable)
PHP Bug Type: PEAR related
Bug description: Add touch() after copy()
Description:
------------
Here's the patch
Index: Installer.php
===================================================================
RCS file: /repository/php-src/pear/PEAR/Installer.php,v
retrieving revision 1.104
diff -u -r1.104 Installer.php
--- Installer.php 31 Aug 2003 16:41:27 -0000 1.104
+++ Installer.php 1 Sep 2003 19:15:56 -0000
@@ -230,6 +230,8 @@
return $this->raiseError("failed to write $dest_file",
PEAR_INSTALLER_FAILED);
}
+ $stat = stat($orig_file);
+ @touch($dest_file, $stat[9]);
$this->log(3, "+ cp $orig_file $dest_file");
if (isset($atts['md5sum'])) {
$md5sum = md5_file($dest_file);
@@ -963,6 +965,8 @@
$this->rollbackFileTransaction();
return $this->raiseError("failed to copy $bn to
$copyto");
}
+ $stat = stat($ext['file']);
+ @touch($copyto, $stat[9]);
$pkginfo['filelist'][$bn] = array(
'role' => 'ext',
'installed_as' => $dest,
--
Edit bug report at http://bugs.php.net/?id=25345&edit=1
--
Try a CVS snapshot (php4): http://bugs.php.net/fix.php?id=25345&r=trysnapshot4
Try a CVS snapshot (php5): http://bugs.php.net/fix.php?id=25345&r=trysnapshot5
Fixed in CVS: http://bugs.php.net/fix.php?id=25345&r=fixedcvs
Fixed in release: http://bugs.php.net/fix.php?id=25345&r=alreadyfixed
Need backtrace: http://bugs.php.net/fix.php?id=25345&r=needtrace
Try newer version: http://bugs.php.net/fix.php?id=25345&r=oldversion
Not developer issue: http://bugs.php.net/fix.php?id=25345&r=support
Expected behavior: http://bugs.php.net/fix.php?id=25345&r=notwrong
Not enough info: http://bugs.php.net/fix.php?id=25345&r=notenoughinfo
Submitted twice: http://bugs.php.net/fix.php?id=25345&r=submittedtwice
register_globals: http://bugs.php.net/fix.php?id=25345&r=globals
PHP 3 support discontinued: http://bugs.php.net/fix.php?id=25345&r=php3
Daylight Savings: http://bugs.php.net/fix.php?id=25345&r=dst
IIS Stability: http://bugs.php.net/fix.php?id=25345&r=isapi
Install GNU Sed: http://bugs.php.net/fix.php?id=25345&r=gnused