com php-src: fix phar copy-on-write: ext/phar/phar_object.c
| From: | Anatol Belski | Date: | Thu, 28 Aug 2014 15:35:54 +0000 |
| Subject: | com php-src: fix phar copy-on-write: ext/phar/phar_object.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-81268@lists.php.net to get a copy of this message | ||
Commit: f4e04b9fb14410cdbd853d3b4111793d9ab5692e
Author: Anatol Belski <ab@php.net> Thu, 28 Aug 2014 17:35:54 +0200
Parents: 9f1b68eda574e18ec0f8e60e9fe28d6319ed36c9
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=f4e04b9fb14410cdbd853d3b4111793d9ab5692e
Log:
fix phar copy-on-write
Changed paths:
M ext/phar/phar_object.c
Diff:
diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c
index 2d34cf6..ed3e60a 100755
--- a/ext/phar/phar_object.c
+++ b/ext/phar/phar_object.c
@@ -3421,6 +3421,7 @@ PHP_METHOD(Phar, copy)
}
}
+ tmp_len = (int)newfile_len;
if (phar_path_check(&newfile, &tmp_len, &pcr_error) > pcr_is_ok) {
zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0 TSRMLS_CC,
"file \"%s\" contains invalid characters %s, cannot be copied from
\"%s\" in phar %s", newfile, pcr_error, oldfile, phar_obj->archive->fname);