Re: ZipArchive problems. Possible bug (Livelock)

From: Date: Thu, 23 Jul 2009 13:29:31 +0000
Subject: Re: ZipArchive problems. Possible bug (Livelock)
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-45064@lists.php.net to get a copy of this message
hi, Please open a bug report here: http://bugs.php.net with a script and an archive (if necessary) to reproduce your problem. Cheers, On Thu, Jul 23, 2009 at 3:20 PM, Alpár Török<torokalpar@gmail.com> wrote: > Hi all, > > The short version is : on a corrupted zip, getStream never returns, > and eats up the whole processor. CHECKCONS doesn't help. > > The long version: >  I have scripts that process data. Data arrives as zip archives. The > data import process halts, eating up all server CPU. I have analyzed > the incoming zips  using the test option of 7zip [1] , i found that > the the problem occurs with zips that contain one or more files for > witch 7zip reports that CRC has failed. These zips open without an > error, and once i try to get stream, for the faulty file, the call > never returns, and eats up the cpu. I tried to use the   CHECKCON flag > at opening, in the hope that the zip won't open, and thus i can just > throw it away, but it doesn't seem to help. Looking in the source i > wound on line 1174 of php_zip.c [2] , that no flag parameter is passed > to zip_open. I don't have a developement environment, so i can > recompile / and or debug this problem. > > I have tested with 5.2.10 > > > > [1] http://www.7-zip.org/ - The 7zip homepage > [2] the line reads : rsrc_int->za = zip_open(resolved_path, 0, &err); > -- > Alpar Torok > > -- > PHP Internals - PHP Runtime Development Mailing List > To unsubscribe, visit: http://www.php.net/unsub.php > > -- Pierre http://blog.thepimp.net | http://www.libgd.org

« previous php.internals (#45064) next »