1
0
mirror of https://github.com/php/php-src.git synced 2026-04-29 11:13:36 +02:00
Commit Graph

66 Commits

Author SHA1 Message Date
Greg Beaver dd5cd94476 MFB: fix swapping of time/date in timestamp saving for zip, which can cause crash on windows 2009-03-01 06:58:23 +00:00
Greg Beaver 9633dc158b MFB: cosmetics: fix warning (only affects suncc) 2009-02-21 02:34:01 +00:00
Greg Beaver 6a9197f1ad MFB: fix zip access to work in all compilers, present and future, and on all arches without potential for bus errors. This removes PHAR_ZIP_PACK in favor of a safer approach 2009-02-20 05:06:52 +00:00
Greg Beaver 4eed2d8ffc MFB: fix memleaks on zip corruption 2009-02-16 18:55:19 +00:00
Greg Beaver 5b9430b5d4 MFB: fix all remaining big-endian issues 2009-02-15 20:29:26 +00:00
Greg Beaver a249c4d77a MFB: fix getting/setting of all 16/32 bit on zip 2009-02-15 19:23:06 +00:00
Sebastian Bergmann 7f4dc8702a Bump copyright year, 3 of 3. 2008-12-31 11:12:40 +00:00
Antony Dovgal 79ec5dc2b9 fix ZTS build 2008-10-12 21:09:10 +00:00
Greg Beaver c448cb165c MFB: add tests for copy-on-write support
- fix metadata handling with cached phars
 - fix virtual_dirs with rmdir
 - ensure that after copy-on-write, all existing Phar objects link to the newly copied phar data
2008-10-12 19:40:30 +00:00
Greg Beaver df7756f244 MFB: cosmetics/maintainability: reduce code redundancy on error conditions 2008-10-11 21:23:13 +00:00
Greg Beaver 7a04372a2d MFB: work around crap stream filter implementation, update tests for compressed aliases in zip-based phar so they actually test the compression 2008-10-11 21:02:53 +00:00
Greg Beaver 0653e0a142 MF53: workaround for Bug #46147 for PHP < 5.2.7 2008-09-22 01:40:51 +00:00
Greg Beaver 2f54ca9c7a MFB: increase code coverage, fix bzip2-compressed alias in zip 2008-09-14 06:32:52 +00:00
Steph Fox cd011d1e9a - MFB 2008-08-31 20:54:28 +00:00
Steph Fox c6aa379d74 - This is as good as it gets in HEAD at present (~30% tests fail here) 2008-08-01 13:45:06 +00:00
Antony Dovgal ae56a0a11f fix build 2008-06-12 10:31:40 +00:00
Greg Beaver ca6d36efb8 MFB: refactor function names for clarity. No functionality change 2008-05-30 22:39:33 +00:00
Steph Fox 76a9ec377b - MFB major fixes
* found felipe's segfault in util.c and fixed the segfault (3 tests fail due to odd behavior of . and .. on this machine)
   * fixed serious flaws in the setting/resetting of is_data - now it works properly.  Assume
     all new PharData are tar-based, and allow passing Phar::ZIP to PharData constructor to override this
   * fix broken earlier commit, introduced segfault that broke 20 tests here
2008-05-24 14:18:31 +00:00
Greg Beaver 11fb7561f0 enable by default statically instead of shared
this is done by removing zlib/bz2 explicit dependencies because they are unnecessary
we only ever use the stream filter, and the check for existence has
been moved to runtime where it is after startup
2008-05-17 20:07:38 +00:00
Greg Beaver 82dc03941a fix weird alias issues, add tests to check for new-found problems 2008-05-12 20:42:07 +00:00
Greg Beaver 30eca098e4 fix minor memleak 2008-05-12 17:40:14 +00:00
Steph Fox dba1c11685 - Make sure default alias is set in phar.zip
- Add test
2008-05-12 17:12:56 +00:00
Greg Beaver 25a6be6cde fix windows build 2008-05-08 03:10:18 +00:00
Greg Beaver 53e02373d0 fix handling of mounted entries when flushing in all phars, and of deleted entries with open references in tar-based phars, do not extract mounted entries, add to test 2008-05-08 02:58:45 +00:00
Greg Beaver f134a909c3 optimize phar filename extension detection to first search through known phars. This eliminates several stat/realpath calls for archives with lots of files 2008-05-07 17:24:22 +00:00
Greg Beaver 96d4c2b62f fix zip metadata for archive/fix perms for file in zip/all.phpt test 2008-05-06 21:46:26 +00:00
Greg Beaver 5ba8ca70a4 fix alias overloading handling for archives that are not in use 2008-05-06 21:14:53 +00:00
Greg Beaver 93fd16ef4d fix possible read past end of buffer by ridiculously stupid convoluted logic (I wrote it, I can call it that) reported by valgrind 2008-04-30 23:49:09 +00:00
Greg Beaver 5bf3d1d362 fix invalid free 2008-04-27 07:04:56 +00:00
Greg Beaver fade22bfd8 fix ridiculously critical omission in zip flush - we never set compressed file size! Augment zip test for bz2/zlib-compressed alias files to increase code coverage 2008-04-26 23:02:51 +00:00
Greg Beaver ad6e7fc667 add screening of alias to reading of zip archives, and test for bad aliases 2008-04-26 22:04:04 +00:00
Greg Beaver 3d858f4aa9 implement symbolic link support within a tar-based phar archive
this also resulted in a major fix for mounted directories, which were recycling the 'link' field which
could cause stupid conflicts with actual links, so move that to new 'tmp' field.
2008-04-21 06:17:51 +00:00
Greg Beaver 56650fa4cd amend zip test to actually test file perms creation/reading and fix severely broken permissions creation 2008-04-20 05:41:41 +00:00
Greg Beaver 0cf701fe4e new test for unix 'zip' command-created zip archives 2008-04-20 05:19:20 +00:00
Greg Beaver e94aaeada9 new test for unsupported compression versions, vastly enhance error messages on unsupported compression methods, fix memleak 2008-04-19 06:18:13 +00:00
Greg Beaver bd3ddde29f new test for truncated file comment, fix memleak found by test 2008-04-19 05:39:42 +00:00
Greg Beaver 531caa6393 new test for corrupted zip with mis-matched entry counts, and fix memleaks in this test case 2008-04-19 05:30:48 +00:00
Greg Beaver 159e39d81d load entire end of zip instead of weird 8k looping, logic is much simpler, and it's only 65k instead of 8k 2008-04-16 19:48:31 +00:00
Greg Beaver 4e584728e5 fix end of directory locator detection code, add failing test for large zips 2008-04-16 04:34:25 +00:00
Greg Beaver e465dc8711 add support for big-endian systems to zip implementation 2008-04-15 03:29:21 +00:00
Greg Beaver 54cfa7437c correct last commit (comparison of "nu" in wrong order) 2008-03-28 21:03:29 +00:00
Greg Beaver 6ff19e08f4 fix Bug #13518: comparision of a char* pointer with a string literal 2008-03-27 21:31:27 +00:00
Greg Beaver 6cef8da201 move all blah++ to ++blah where possible for those with crapass compilers 2008-03-22 22:11:49 +00:00
Steph Fox 8343d7c139 - A bit more work on PharData creation/conversion.
- If readonly=0, why not $phardata->convertToPhar()?
- Known issue with directories creating 'as-file' copies within the archive (all formats)
@Greg/Marcus/Tony: This passes all tests on my box, 5.2/5.3/release_ts/debug_ts, and I can't find any more memleaks. Obviously this is too good to be true, so if conversion is still messy elsewhere please feel free to fix, or bug and assign to me.
2008-03-03 08:41:15 +00:00
Steph Fox d4cf7e47f6 Right problem, wrong solution. Also missed an '= 1' , thanks Marcus 2008-03-01 22:28:33 +00:00
Steph Fox 001ffec19f Initial support for PharData object.
Note: two tests currently fail. IMHO we should be throwing E_ERROR on encountering a corrupted archive, not trying to throw a trail of exceptions...
New tests still to be written, not all functionality is in place yet.
2008-02-27 21:34:26 +00:00
Steph Fox 8513db73bb A bunch of stuff to do with filename conversion. Hopefully it won't sink the ship. 2008-02-24 22:29:06 +00:00
Greg Beaver dc43219add down to 1 failing zip test with this commit 2008-02-23 18:28:36 +00:00
Greg Beaver 94f39ee501 fix unfreed value 2008-02-23 18:26:20 +00:00
Greg Beaver a0e5e40663 port same fix from tar.c to zip.c 2008-02-23 18:24:41 +00:00