Commit Graph

49 Commits

Author SHA1 Message Date
Greg Beaver
dcc919c449 fix Bug #46194: SIGSEGV when requested file is not found 2008-09-30 02:40:17 +00:00
Greg Beaver
e1d0a964da fix 017.phpt in streams.c, and very dangerous intercepting of file functions in all cases introduced in multi-threaded fix 2008-09-26 23:34:57 +00:00
Greg Beaver
1847779210 fix bug #46178: memory leak in ext/phar 2008-09-26 16:29:44 +00:00
Greg Beaver
9eb83b6ae9 fix minor issues found by ICC (unused variables and the like) 2008-09-13 22:30:55 +00:00
Steph Fox
7b74a7711c - cs, update package files following RC1 (just to keep it all in sync) 2008-08-31 21:01:12 +00:00
Greg Beaver
642f6aa673 remove superfluous double variable declaration, merge from pecl/phar 2008-08-31 06:28:01 +00:00
Greg Beaver
f679e900dd remove orphaned code, merge from pecl/phar 2008-08-31 06:13:42 +00:00
Greg Beaver
5c3749021a remove unused variables, merge from pecl/phar 2008-08-31 06:09:37 +00:00
Greg Beaver
c3e8485971 fix bug #45792: bz2 compressed files in zip failure 2008-08-21 05:17:28 +00:00
Dmitry Stogov
878946a34f Fixed bug #45613 Segfault when using is_file() on Apache-2.2.8 2008-08-14 13:01:28 +00:00
Steph Fox
4e5280a7a2 - ws/cs, macros, code that only affects other branches
- some unsynced changes need valgrind testing before they can go into this branch, see PECL/HEAD
2008-08-01 13:48:45 +00:00
Antony Dovgal
b53da9cd80 fix folding 2008-07-29 10:52:08 +00:00
Dmitry Stogov
c48c63f5e6 Improved webPhar speed (frontcontroller11.phar.phpt is disabled, should be removed) 2008-07-22 07:03:00 +00:00
Dmitry Stogov
68537af530 Fixed directory reanming/deletion 2008-07-20 14:42:34 +00:00
Dmitry Stogov
67b77b06e5 Fixed search on uninitialized data 2008-07-17 14:05:07 +00:00
Dmitry Stogov
5c631e8765 Fixed wrong arguments order 2008-07-17 13:22:32 +00:00
Dmitry Stogov
53bbf1238c Extensions MUST NOT manipulate with internal functions from EG(function_table) in run-time. It may cause problems with opcode caches and in multi-threaded environment. Now the same functions are overriden at MINIT and call original functions or PHAR ones dependent on flag setting. 2008-07-10 11:36:50 +00:00
Antony Dovgal
ae7eff10e8 add zero-terminator to the delimiter (and make valgrind happy) 2008-07-09 14:15:41 +00:00
Greg Beaver
37c684ab3d in preparation for a performance optimization that involves
eliminating phar's interception of zend_compile in favor of a new to-be-added hook in PHP 5.3+,
allow "include 'phar:///path/to/my.phar';" to work as equivalent to
php /path/to/my.phar
this slight change in scripting still allows inclusion and execution of phar stub, but removes the need to
check and modify path in zend_compile, which allows us to play much nicer with external tools like
debuggers/opcode caches
2008-06-27 01:21:12 +00:00
Steph Fox
b9e8695e75 - One solution for the openssl issues
- config.m4 needs bringing into line with config.w32, there may be broken behaviour under *nix until this is done
2008-06-23 19:18:01 +00:00
Greg Beaver
3a8b14f83f fix inode calculation, we need fname to be set for phar/tar formats prior to manifest parsing 2008-06-22 00:50:32 +00:00
Steph Fox
b964ec6e5d - ws 2008-06-21 18:57:53 +00:00
Greg Beaver
eb0a98939a PHP 5.2 fixes to direct include of compressed archives 2008-06-21 17:05:18 +00:00
Steph Fox
fc08a7cc2f The only reason that particular 'real solution' wasn't applied in the first place was that it also breaks the shared build
Maybe we don't need to call a non-existent dtor if we're going to physically apply zend_hash_graceful_reverse_destroy()?
- This works on my box, please test under *nix/OSX
2008-06-20 12:21:32 +00:00
Greg Beaver
7cc6b9f3f5 making progress - up to 42/phar vs. 48/disk with these optimizations 2008-06-20 05:42:58 +00:00
Greg Beaver
5233505043 revert really bad solution to the zend_init_rsrc_list/zend_destroy_rsrc_list problem, replace with real solution 2008-06-20 04:50:11 +00:00
Steph Fox
aa694b8b51 - Kill 10 MSVC compiler warnings due to type conflict
- Make cached manifest test platform agnostic
- Comment out zend_(init|destroy)_rsrc_list() and associated references

@Greg: cached manifest test (now) passes here regardless, make of that what you will
2008-06-18 15:06:50 +00:00
Greg Beaver
cbe23b9f20 fix windows build and more performance jumps (these are minor)
implement real copy-on-write
use virtual_dirs for wrapper stat
2008-06-18 06:38:47 +00:00
Greg Beaver
d8d31bc591 remove unused variables in phar_fix_filepath
copy virtual_dirs to avoid segfault on multi-process
fix metadata reading for phar.cache_list
initialize manifest to exact size needed (performance increase)
fix freeing of signature on error to use the correct persist value (fixes segfault on error in cache.list)
reset EG(regular_list) so it is identical to how we found it
2008-06-16 04:10:53 +00:00
Greg Beaver
c353e9277e minor performance improvement 2008-06-15 23:00:46 +00:00
Greg Beaver
4104786072 another optimization - move inode hash to initial manifest parsing, improves runtime perf of stat slightly 2008-06-15 21:42:20 +00:00
Greg Beaver
d8ed660a02 minor optimization 2008-06-15 21:15:29 +00:00
Greg Beaver
04e257a8e1 HUGE speed improvement, from 19 req/sec to 27 req/sec for phpMyAdmin - now speed with apc+phar.cache_list = on-disk speedcvs diff -u |less This is by generating a list of virtual directories and using those in stat calls instead of scanning the whole manifest hash table. on-disk phpMyAdmin = 28 req/sec 2008-06-15 18:15:48 +00:00
Greg Beaver
5ff4deaa53 full refactor of signatures complete - now to implement them for tar as a starting point 2008-06-13 20:15:19 +00:00
Felipe Pena
d61f32d021 - Fix build (ZTS) 2008-06-13 13:06:46 +00:00
Greg Beaver
9c8d13fd6c partial refactor - move signature verification into its own function, in preparation for tar/zip signature support.
next is signature creation
2008-06-13 06:34:41 +00:00
Greg Beaver
98f2dc2aca [DOC] add phar.cache_list, a PATH_SEPARATOR-separated list of full paths to phar archives to cache
at startup.  This caches the manifest, so that on first access to a phar archive, no file manifest parsing occurs.

This could use further tweaking.  For instance, the full copy of the manifest into the current process may be unnecessary if refcounting could be external
to the manifest.  This would be another significant gain.  With APC, I measure a slight perf increase to 19 req/sec up from 16 req/sec, without it approaches
regular PHP at 3.8 req/sec (regular is 4 req/sec).  This is benching phpMyAdmin
2008-06-12 18:56:23 +00:00
Greg Beaver
eb77b80b9d fix compile warnings if openssl is enabled statically. fix dangerous use of wrong length var in openssl signature verification 2008-06-09 16:07:18 +00:00
Greg Beaver
5fbeb235d2 add openssl signing support. This adds an extra parameter
for the contents of the exported private key to Phar->setSignatureAlgorithm, and expects the public key to be in
a file named blah.phar.pubkey in the same directory as the phar blah.phar.  This works with openssl static or
shared and fails gracefully if openssl is not present without adding a dependency. config.w32 needs updating to match config.m4 [DOC]
2008-06-01 04:21:26 +00:00
Greg Beaver
83e491b2c3 fix corrupted zips, fix postprocess for compressed zip file 2008-05-30 22:49:33 +00:00
Greg Beaver
8b600a72dc refactor function names for clarity. No functionality change 2008-05-30 22:38:46 +00:00
Greg Beaver
4cc79b39b4 fix PECL bug #13981: Third-party zips fail entry interrogation 2008-05-29 17:34:50 +00:00
Stanislav Malyshev
370aafc62b Fix code path in phar_open_compiled_file() that tries
to open not-yet-loaded phar and fails on compressed files
# By Gregory's request
# Sorry, can't find how to write test case for that - it reproduces
# for me only under bytecode-caching. Suggestions welcome.
2008-05-28 21:42:21 +00:00
Greg Beaver
4b035dae5f 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-22 06:33:09 +00:00
Greg Beaver
1f661c81c4 fix offset detection in tar files 2008-05-21 22:00:43 +00:00
Greg Beaver
4aa4f1fabb 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:22 +00:00
Steph Fox
6a0682d986 - MFH
- Make internal code forward-compatible. This included a binary cast in the default stub, hence test updates.
2008-05-14 21:29:51 +00:00
Steph Fox
4d169ebcfc - Allow broken.dirnames to use phar too
- Add test
- Kill MSVC compiler warning
2008-05-13 14:11:24 +00:00
SVN Migration
16b4d8e0e1 This commit was manufactured by cvs2svn to create branch 'PHP_5_3'. 2008-05-12 21:03:49 +00:00