diff options
author | Anatol Belski <ab@php.net> | 2013-03-23 21:00:46 +0100 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2013-03-23 21:00:46 +0100 |
commit | ec25e99193d772d51b5f2e5406d98f5e90f0bc00 (patch) | |
tree | a9b4fd46f58a1247bd618dcdfbaf7b5c8870e73c /ext/zip | |
parent | 01583bdc36aea0cbd711a01acbf36ed452f4f918 (diff) | |
parent | 04b492a5fef25c70fb42b0734e04d44cbc5a9241 (diff) | |
download | php-git-ec25e99193d772d51b5f2e5406d98f5e90f0bc00.tar.gz |
Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
Reworked the changes for bug #64452
Diffstat (limited to 'ext/zip')
-rw-r--r-- | ext/zip/lib/zip_close.c | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/ext/zip/lib/zip_close.c b/ext/zip/lib/zip_close.c index e66c56697b..576be3b353 100644 --- a/ext/zip/lib/zip_close.c +++ b/ext/zip/lib/zip_close.c @@ -88,9 +88,6 @@ zip_close(struct zip *za) if (za == NULL) return -1; - if (za->zp == NULL) - return -1; - if (!_zip_changed(za, &survivors)) { _zip_free(za); return 0; @@ -196,7 +193,7 @@ zip_close(struct zip *za) } else { /* copy existing directory entries */ - if (fseeko(za->zp, za->cdir->entry[i].offset, SEEK_SET) != 0) { + if ((NULL == za->zp) || (fseeko(za->zp, za->cdir->entry[i].offset, SEEK_SET) != 0)) { _zip_error_set(&za->error, ZIP_ER_SEEK, errno); error = 1; break; |