From: Sterling Hughes Date: Sat, 2 Jun 2001 05:12:44 +0000 (+0000) Subject: Patch from Daniel Beckham, fetch the entry resource id, not the directory X-Git-Tag: PRE_GRANULAR_GARBAGE_FIX~148 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=aa281a07713ed719740deebd44dd4b6daaa024b0;p=php Patch from Daniel Beckham, fetch the entry resource id, not the directory resource id and fix prototype. --- diff --git a/ext/zip/zip.c b/ext/zip/zip.c index dbc013b8c2..29819c66a0 100644 --- a/ext/zip/zip.c +++ b/ext/zip/zip.c @@ -226,7 +226,7 @@ PHP_FUNCTION(zip_entry_compressionmethod) } /* }}} */ -/* {{{ proto bool zip_open(resource zip_dp, resource zip_entry, string mode) +/* {{{ proto bool zip_entry_open(resource zip_dp, resource zip_entry, string mode) Open a Zip File, pointed by the resource entry */ PHP_FUNCTION(zip_entry_open) { @@ -240,7 +240,7 @@ PHP_FUNCTION(zip_entry_open) } ZEND_FETCH_RESOURCE(archive_p, ZZIP_DIR *, zzip_dp, -1, le_zip_dir_name, le_zip_dir); - ZEND_FETCH_RESOURCE(entry, php_zzip_dirent *, zzip_dp, -1, le_zip_entry_name, le_zip_entry); + ZEND_FETCH_RESOURCE(entry, php_zzip_dirent *, zzip_ent, -1, le_zip_entry_name, le_zip_entry); entry->fp = zzip_file_open(archive_p, entry->dirent.d_name, O_RDONLY | O_BINARY);