diff options
Diffstat (limited to 'ext/zlib')
-rw-r--r-- | ext/zlib/tests/bug_52944-darwin.phpt | 24 | ||||
-rw-r--r-- | ext/zlib/tests/bug_52944.phpt | 4 | ||||
-rw-r--r-- | ext/zlib/tests/gzfile_variation4.phpt | 2 | ||||
-rw-r--r-- | ext/zlib/tests/readgzfile_variation4.phpt | 2 | ||||
-rw-r--r-- | ext/zlib/zlib.c | 12 | ||||
-rw-r--r-- | ext/zlib/zlib_filter.c | 2 | ||||
-rw-r--r-- | ext/zlib/zlib_win32_howto.txt | 2 |
7 files changed, 16 insertions, 32 deletions
diff --git a/ext/zlib/tests/bug_52944-darwin.phpt b/ext/zlib/tests/bug_52944-darwin.phpt deleted file mode 100644 index c25babadf..000000000 --- a/ext/zlib/tests/bug_52944-darwin.phpt +++ /dev/null @@ -1,24 +0,0 @@ ---TEST-- -Bug #52944 (segfault with zlib filter and corrupted data) ---SKIPIF-- -<?php if (!extension_loaded("zlib")) print "skip"; ?> -<?php -if (PHP_OS != 'Darwin') { - die("skip Darwin only"); -} ---INI-- -allow_url_fopen=1 ---FILE-- -<?php -require dirname(__FILE__) . "/bug_52944_corrupted_data.inc"; - -$fp = fopen('data://text/plain;base64,' . $data, 'r'); -stream_filter_append($fp, 'zlib.inflate', STREAM_FILTER_READ); -var_dump(fread($fp,1)); -var_dump(fread($fp,1)); -fclose($fp); -echo "Done.\n"; ---EXPECT-- -string(1) "%" -string(1) "C" -Done. diff --git a/ext/zlib/tests/bug_52944.phpt b/ext/zlib/tests/bug_52944.phpt index ff82d29cc..68bd53791 100644 --- a/ext/zlib/tests/bug_52944.phpt +++ b/ext/zlib/tests/bug_52944.phpt @@ -2,10 +2,6 @@ Bug #52944 (segfault with zlib filter and corrupted data) --SKIPIF-- <?php if (!extension_loaded("zlib")) print "skip"; ?> -<?php -if (PHP_OS == 'Darwin') { - die("skip not for Darwin"); -} --INI-- allow_url_fopen=1 --FILE-- diff --git a/ext/zlib/tests/gzfile_variation4.phpt b/ext/zlib/tests/gzfile_variation4.phpt index 331023156..9b3128125 100644 --- a/ext/zlib/tests/gzfile_variation4.phpt +++ b/ext/zlib/tests/gzfile_variation4.phpt @@ -2,7 +2,7 @@ Test function gzfile() by substituting argument 1 with float values. --SKIPIF-- <?php -if (!extension_loaded(zlib)) die ('skip zlib extension not available in this build'); +if (!extension_loaded('zlib')) die ('skip zlib extension not available in this build'); ?> --FILE-- <?php diff --git a/ext/zlib/tests/readgzfile_variation4.phpt b/ext/zlib/tests/readgzfile_variation4.phpt index 00211f7df..32f434cba 100644 --- a/ext/zlib/tests/readgzfile_variation4.phpt +++ b/ext/zlib/tests/readgzfile_variation4.phpt @@ -2,7 +2,7 @@ Test function readgzfile() by substituting argument 1 with float values. --SKIPIF-- <?php -if (!extension_loaded(zlib)) die ('skip zlib extension not available in this build'); +if (!extension_loaded('zlib')) die ('skip zlib extension not available in this build'); ?> --FILE-- <?php diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c index 705fb5dd5..25804597b 100644 --- a/ext/zlib/zlib.c +++ b/ext/zlib/zlib.c @@ -34,6 +34,18 @@ #include "ext/standard/php_string.h" #include "php_zlib.h" +/* + * zlib include files can define the following preprocessor defines which rename + * the corresponding PHP functions to gzopen64, gzseek64 and gztell64 and thereby + * breaking some software, most notably PEAR's Archive_Tar, which halts execution + * without error message on gzip compressed archivesa. + * + * This only seems to happen on 32bit systems with large file support. + */ +#undef gzopen +#undef gzseek +#undef gztell + ZEND_DECLARE_MODULE_GLOBALS(zlib); /* {{{ Memory management wrappers */ diff --git a/ext/zlib/zlib_filter.c b/ext/zlib/zlib_filter.c index c81500854..ec8f6c8e9 100644 --- a/ext/zlib/zlib_filter.c +++ b/ext/zlib/zlib_filter.c @@ -391,7 +391,7 @@ static php_stream_filter *php_zlib_filter_create(const char *filtername, zval *f if (zend_hash_find(HASH_OF(filterparams), "level", sizeof("level"), (void**) &tmpzval) == SUCCESS) { tmp = **tmpzval; - /* Psuedo pass through to catch level validating code */ + /* Pseudo pass through to catch level validating code */ goto factory_setlevel; } break; diff --git a/ext/zlib/zlib_win32_howto.txt b/ext/zlib/zlib_win32_howto.txt index a4e01a484..e2a2b79cc 100644 --- a/ext/zlib/zlib_win32_howto.txt +++ b/ext/zlib/zlib_win32_howto.txt @@ -1,7 +1,7 @@ Rules for building ZLIB ----------------------- -The zlib project requires the folowing files: +The zlib project requires the following files: php_build\zlib\include\zlib.h php_build\zlib\include\zconf.h |