php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #48217 ZipArchive->open unable to open certain zip files
Submitted: 2009-05-10 00:03 UTC Modified: 2009-05-10 00:12 UTC
From: mb at smartftp dot com Assigned:
Status: Not a bug Package: Zip Related
PHP Version: 5.2CVS-2009-05-10 (snap) OS: Windows Vista
Private report: No CVE-ID: None
 [2009-05-10 00:03 UTC] mb at smartftp dot com
Description:
------------
ZipArchive is unable to open a zip file containing 247 files and 4 folders.

I have created a .zip file using ZipArchive. This is all good. However when trying to open this zip archive ZipArchive->open fails with error 11.

The zip file looks good since I'm able to open it with WinRAR etc.

The test.zip with the test.php is provided in the following archive:
http://www.smartftp.com/upload/zipbug.zip

Regards,
Mat
SmartFTP

Reproduce code:
---------------
$extract = new ZipArchive;
$open = $extract->open($file, ZIPARCHIVE::CHECKCONS);
if($open === TRUE)
{
  print("ok");
}
else
{
  print("error");

  // readfile always works. Thus no permission problem.
  readfile($file);
}

Expected result:
----------------
ok

Actual result:
--------------
error

and output of file.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2009-05-10 00:12 UTC] mb at smartftp dot com
I'm unable to reproduce it this way.
 
PHP Copyright © 2001-2019 The PHP Group
All rights reserved.
Last updated: Tue May 21 17:01:26 2019 UTC