Commit Graph

4857 Commits

Author SHA1 Message Date
Antony Dovgal
82f70c9493 fix leaks on error 2007-02-01 13:45:25 +00:00
Antony Dovgal
c98dcd5a21 use length - 1 when we fetch it from hashes 2007-01-26 15:33:18 +00:00
Rasmus Lerdorf
49dbf804ad Fix typo 2007-01-25 06:12:58 +00:00
Ilia Alshanetsky
49c0823800 Added safety checks to the code 2007-01-25 00:27:19 +00:00
Ilia Alshanetsky
094a5717b1 Eliminate strcat() and strcpy() 2007-01-25 00:26:51 +00:00
Ilia Alshanetsky
eb6b99d7df strcat() -> strlcat() 2007-01-24 00:45:54 +00:00
Dmitry Stogov
933c26de41 Fixed bug #39367 (clearstatcache() doesn't clear realpath cache)
Fixed bug #40092 (chroot() doesn't clear realpath cache)
2007-01-22 09:31:46 +00:00
Antony Dovgal
eae1072ccc MFH 2007-01-22 08:21:57 +00:00
Antony Dovgal
2c36778e47 MFH: fix #40191 (use of array_unique() with objects triggers segfault) 2007-01-22 08:17:26 +00:00
Antony Dovgal
ebd7c13e8b MFH: fix #40168 2007-01-19 14:50:11 +00:00
Ilia Alshanetsky
aeddf73dc4 Fix win32 build 2007-01-19 00:17:43 +00:00
Ilia Alshanetsky
ef3fcf2894 Added read-timeout context option "timeout" for HTTP streams.
# A patch mostly by Hannes
2007-01-19 00:02:13 +00:00
Antony Dovgal
84a827e0d4 MFH 2007-01-18 16:21:32 +00:00
Antony Dovgal
d6a4586197 MFH 2007-01-17 08:25:32 +00:00
Antony Dovgal
7ad1c3c5f2 MFH: add trailing '\0' to stream hashes 2007-01-15 17:07:08 +00:00
Hannes Magnusson
a6ff74de28 Fix typo in error message 2007-01-14 14:22:40 +00:00
Ilia Alshanetsky
f7d1d3ef44 Improve validation of argnum, width and precision. 2007-01-13 16:31:17 +00:00
Ilia Alshanetsky
25e7373009 Use long instead of int where long is expected. 2007-01-12 02:03:59 +00:00
Ilia Alshanetsky
2ae036f038 Fixed bug #40098 (php_fopen_primary_script() not thread safe).
Adjusted previous fixes for similar issue to handle sysconf() failures
2007-01-12 01:46:11 +00:00
Sara Golemon
5e74c607a2 MFH 2007-01-11 02:33:07 +00:00
Hannes Magnusson
3e0e2bb49d Fix ifdefs 2007-01-10 14:40:06 +00:00
Dmitry Stogov
5709b64739 Close open files in case of failure (Amit) 2007-01-09 16:27:17 +00:00
Ilia Alshanetsky
60e20922eb Use safe_emalloc() rather then emalloc() 2007-01-08 14:24:59 +00:00
Dmitry Stogov
f694c1f1db Improved proc_open(). Now on Windows it can run external commands not through CMD.EXE 2007-01-06 09:02:02 +00:00
Hannes Magnusson
3f9a4baa31 Fix test according to bug#40009 2007-01-05 15:22:35 +00:00
Ilia Alshanetsky
7d901eacbe %f -> %F 2007-01-05 15:06:55 +00:00
Ilia Alshanetsky
a078b56326 Fixed bug #40009 (http_build_query(array()) returns NULL). 2007-01-03 23:16:56 +00:00
Nuno Lopes
8a806d186e +- Fixed bug #37619 (proc_open() closes stdin on fork() failure). 2007-01-02 15:29:09 +00:00
Sebastian Bergmann
4223aa4d5e MFH: Bump year. 2007-01-01 09:36:18 +00:00
Nuno Lopes
169b207532 - Fixed bug #36427 (proc_open() / proc_close() leak handles on windows). 2006-12-31 15:27:13 +00:00
Nuno Lopes
877ee65622 Fixed bug #38542 (proc_get_status() returns wrong PID on windows) 2006-12-31 14:47:17 +00:00
Ilia Alshanetsky
78d8808f42 Mark test as being 32bit only 2006-12-30 02:00:51 +00:00
Ilia Alshanetsky
b154f188d1 Simplify code and eliminate strcat() usage 2006-12-28 15:09:29 +00:00
Antony Dovgal
fdfa403388 MFH 2006-12-28 14:17:38 +00:00
Nuno Lopes
54f3ff34b7 oops: remove uneeded code in the skip condition 2006-12-27 15:17:04 +00:00
Nuno Lopes
d07a46ebab add fr_FR@euro to the setlocale list 2006-12-27 15:11:35 +00:00
Ilia Alshanetsky
dc5be15a6f is_numeric_string() optimization 2006-12-26 16:45:39 +00:00
Ilia Alshanetsky
52d53543ac Allocation safety checks 2006-12-25 22:36:57 +00:00
Antony Dovgal
6ac8ffdfea MFH 2006-12-25 22:12:46 +00:00
Ilia Alshanetsky
7efb0a14f4 Use safe_emalloc() 2006-12-25 21:41:04 +00:00
Ilia Alshanetsky
652c7096b2 Fixed test for 64bit systems 2006-12-25 21:07:53 +00:00
Ilia Alshanetsky
0776e56437 Use %F (ignores locale) for internal representation of floats 2006-12-25 16:48:18 +00:00
Antony Dovgal
c52bc49f50 fix test 2006-12-25 14:27:51 +00:00
Antony Dovgal
04d4811532 MFH 2006-12-25 11:50:31 +00:00
Antony Dovgal
6e8a7d7b20 fix tests 2006-12-25 11:16:23 +00:00
Ilia Alshanetsky
f40ebf4171 Fixed bug #36392 (wrong number of decimal digits with %e specifier in
sprintf).
2006-12-22 15:29:41 +00:00
Ilia Alshanetsky
fd8f758ecd Fixed bug #39873 (number_format() breaks with locale & decimal points). 2006-12-22 04:03:15 +00:00
Antony Dovgal
8854c3d51a MFH 2006-12-21 21:37:45 +00:00
Antony Dovgal
6aec52bde7 MFH 2006-12-21 01:18:28 +00:00
Antony Dovgal
0abe62e027 MFH 2006-12-20 23:36:56 +00:00
Antony Dovgal
a0e2ccf490 MFH 2006-12-20 23:30:30 +00:00
Dmitry Stogov
53b088e60c Make MEMORY_LIMIT and ZEND_USE_MALLOC_MM to be always enabled. They don't make any significant slowdown, but incrise maintainability a lot. Note that the setting of memory_limit wasn't changes (neither in main/main.c nor in php.ini) and it still set to 16M. 2006-12-20 10:49:33 +00:00
Hannes Magnusson
1e19ee8785 - Fixed incorrect function names on FreeBSD where inet_pton() was named
__inet_pton() and inet_ntop() was named __inet_ntop()
- Fixed bug #39685 (iconv() - undefined function)
- Fixed bug #38852 (XML-RPC Breaks iconv)
2006-12-20 10:34:36 +00:00
Dmitry Stogov
5d8183f0b2 Support for systems without locale.h 2006-12-19 13:13:29 +00:00
Antony Dovgal
0ecaeb89d3 serialize() should use '.' as decimal point irrespectively to locale 2006-12-19 12:36:44 +00:00
Dmitry Stogov
c43fc2afc8 Fixed bug #39815 (SOAP double encoding is not locale-independent) 2006-12-19 11:54:38 +00:00
Hannes Magnusson
b12e3e1475 Fix tests 2006-12-19 10:03:24 +00:00
Dmitry Stogov
03312cc0d9 Added function stream_socket_shutdown(). It is a wraper for system shutdown() function, that shut downs part of a full-duplex connection 2006-12-19 08:58:58 +00:00
Ilia Alshanetsky
090e14dfda Less hackish support for spaces at the start of tags within strip_tags() 2006-12-18 15:02:16 +00:00
Antony Dovgal
a726dcaa99 MFH: fix #39850 (SplFileObject throws contradictory/wrong error messages when trying to open "php://wrong") 2006-12-18 14:56:20 +00:00
Antony Dovgal
5fc3e649b6 MFH 2006-12-18 11:12:55 +00:00
Antony Dovgal
5e8eecb362 remove the comment, it's not valid anymore 2006-12-18 10:19:52 +00:00
Hannes Magnusson
9ef3575c25 MFH:
- make %f locale aware again
- fix precision loss with %F (noticed by Sebastian Nohn)
- add new tests
2006-12-18 09:26:54 +00:00
Ilia Alshanetsky
7d7248390c Filter fixes:
Fixed possible double encoding problem with sanitizing filters
	Make use of space-strict strip_tags() function
2006-12-18 04:22:05 +00:00
Brian Shire
5bf3df531f Fixed bug #30074
extract with EXTR_REFS was setting EG(unitialized_zval_ptr)->is_ref=1, affecting subsequent usage
  Added test
2006-12-17 20:09:48 +00:00
Andrei Zmievski
8f5310afad Support for 'S' format in unserialize() (forward compatibility with PHP
6)
2006-12-15 00:58:08 +00:00
Ilia Alshanetsky
563221783a Removed deadcode found by Ron Korving 2006-12-13 15:39:12 +00:00
Ilia Alshanetsky
a055e93a27 optimize out strlen() calls
# Patch by Matt Wilmas
2006-12-13 15:31:47 +00:00
Antony Dovgal
dc64595467 MFH 2006-12-12 12:11:51 +00:00
Antony Dovgal
24b312f8d5 MFH: missing part of the fix for #39795 2006-12-12 12:06:37 +00:00
Antony Dovgal
a74c36a335 MFH: fix #39795 (build fails on AIX because crypt_r() uses different data struct) 2006-12-12 07:38:04 +00:00
Ilia Alshanetsky
e64cb1ae4d Optimize extract()
# Patch by Brian Shire
2006-12-10 19:43:03 +00:00
Edin Kadribasic
42e1c9a1e0 Fixed by #39751 by KevinJohnHoffman at gmail dot com 2006-12-10 01:23:41 +00:00
Hannes Magnusson
d9f03aac34 MFH: sys_get_temp_dir() 2006-12-09 18:00:52 +00:00
Ilia Alshanetsky
0236a7eaf4 Fixed bug #29840 (is_executable() does not honor safe_mode_exec_dir
setting).
2006-12-09 16:01:29 +00:00
Antony Dovgal
7df81307c1 MFH 2006-12-08 21:18:43 +00:00
Antony Dovgal
f71a310543 MFH: fix possible issue in the serializer, which might currupt struc when reallocating arguments stack 2006-12-08 20:59:31 +00:00
Antony Dovgal
1edf208421 add new tests by <zoe dot slattery at googlemail dot co dot uk> 2006-12-08 14:39:25 +00:00
Antony Dovgal
feba2edba2 initialize variables 2006-12-07 20:45:58 +00:00
Antony Dovgal
60f3797200 MFH 2006-12-06 16:28:36 +00:00
Antony Dovgal
da53237f41 MFH: add missing 'F' modified (noticed by Matt) 2006-12-06 14:47:36 +00:00
Antony Dovgal
4d44a5b71d MFH: use BSD licensed implementation of double-to-string utilities instead of LGPL one
this patch also fixes thread safety issues in zend_strtod()
2006-12-06 09:52:51 +00:00
Antony Dovgal
9ce985bbae cosmetic improvements 2006-12-05 23:03:19 +00:00
Antony Dovgal
5e7eed6a9a MFH: nuke redundant zval_ptr_dtor() call 2006-12-05 18:42:38 +00:00
Stanislav Malyshev
6b651f8e60 Improve tolower()-related functions on Windows and VC2005 by caching locale and using
tolower_l function.
# Gives 10-18% speedup on bench.php
# Does not change behaviour for non-windows
2006-12-04 18:37:15 +00:00
Ilia Alshanetsky
7999c9d251 Fixed bug #39718 (possible crash if assert.callback is set in ini). 2006-12-03 17:13:11 +00:00
Antony Dovgal
065be7056d MFH: fix AIX build 2006-12-03 13:46:37 +00:00
Ilia Alshanetsky
891bd7888f Use reantrant crypt_r() whenever possible. 2006-11-30 15:59:53 +00:00
Ilia Alshanetsky
466d9ba00a Fixed bug #39648 (Implementation of PHP functions chown() and chgrp() are
not thread safe).
2006-11-29 23:34:49 +00:00
Antony Dovgal
60bb494607 MFH: fix #39673 (file_get_contents causes bus error on certain offsets) 2006-11-29 11:12:59 +00:00
Antony Dovgal
aaf120127e add php_unescape_html_entities() proto to the header
(fixes #39665)
2006-11-28 20:41:07 +00:00
Ilia Alshanetsky
e6a3431315 Fixed bug #39623 (thread safety fixes on *nix for putenv() & mime_magic). 2006-11-26 17:02:13 +00:00
Ilia Alshanetsky
22ff526e99 Added a meta tag to phpinfo() output to prevent search engines from
indexing the page.
2006-11-26 16:26:18 +00:00
Antony Dovgal
93fc85b2af MFH: fix #39621 (str_replace() is not binary safe on strings with equal length) 2006-11-24 21:59:09 +00:00
Nuno Lopes
e8384cbcca more tests 2006-11-24 20:18:54 +00:00
Pierre Joye
efa9b7e20b - MFH: #39538, fgetcsv can't handle starting newlines and trailing odd
number of backslashes (David Soria Parra, Pierre)
2006-11-22 12:59:49 +00:00
Antony Dovgal
df1a1c8441 MFH: fix #39576 (array_walk() doesn't separate userdata zval) 2006-11-22 10:42:41 +00:00
Antony Dovgal
26ed531c64 add test 2006-11-21 18:17:11 +00:00
Antony Dovgal
e412981f7b remove redundant error message
add test by <zoe dot slattery at googlemail dot com>
2006-11-21 17:42:11 +00:00
Antony Dovgal
c220da74ef MFH test 2006-11-20 20:55:51 +00:00
Antony Dovgal
39ad6abbf8 fix test on Solaris 2006-11-20 16:28:26 +00:00
Antony Dovgal
296e2a3775 MFH 2006-11-20 11:12:42 +00:00
Ilia Alshanetsky
714abb7ea1 pack()/unpack() tests 2006-11-19 18:31:07 +00:00
Ilia Alshanetsky
0d338f463c Fixed bug #38770 (unpack() broken with longs on 64 bit machines). 2006-11-19 18:20:48 +00:00
Antony Dovgal
cf04587553 fix tests 2006-11-16 13:49:20 +00:00
Antony Dovgal
36d66521c9 add new tests 2006-11-16 13:01:23 +00:00
Antony Dovgal
d1acb8d4eb add new tests, improve existing ones 2006-11-15 22:44:29 +00:00
Antony Dovgal
eca1911b72 fix leak, add test 2006-11-15 22:10:19 +00:00
Antony Dovgal
9d6f7755b8 fix leak appearing when converting object to NULL
add test
2006-11-15 17:29:08 +00:00
Antony Dovgal
84ff4aaf1a add new tests 2006-11-15 17:27:03 +00:00
Antony Dovgal
70288ef71e fix test on AIX 2006-11-15 12:11:17 +00:00
Antony Dovgal
567aed8316 fix test 2006-11-15 11:27:26 +00:00
Antony Dovgal
60188ad863 fix test 2006-11-15 10:47:26 +00:00
Hannes Magnusson
849a7857ac Fix test (file_put_contents() now uses __toString) 2006-11-15 07:58:02 +00:00
Ilia Alshanetsky
fca0e24410 Added missing object support to file_put_contents(). 2006-11-15 00:20:40 +00:00
Antony Dovgal
6640a1c861 one more test 2006-11-14 22:23:45 +00:00
Antony Dovgal
963b1db67f add new tests 2006-11-14 21:59:57 +00:00
Derick Rethans
de50222d1c - MFH: No idea if we actually support 16 bit systems, but this just looked wrong 2006-11-14 14:42:42 +00:00
Antony Dovgal
923b785fd1 add new test 2006-11-13 21:27:48 +00:00
Antony Dovgal
017f3ae479 don't forget to close the stream when/if flock() fails 2006-11-13 20:31:27 +00:00
Antony Dovgal
34db368fe4 MFH: fix leaks in get_meta_tags() when used with b0rked HTML
add test
2006-11-13 20:18:12 +00:00
Ilia Alshanetsky
d4a64fba74 removed bogus char 2006-11-12 17:23:01 +00:00
Ilia Alshanetsky
e0d385a328 Optimized array functions utilizing php_splice(). 2006-11-12 17:13:22 +00:00
Hannes Magnusson
7b81e554ae MFH: Fixed bug#36975 (natcasesort() causes array_pop() to misbehave) 2006-11-12 01:14:39 +00:00
Dmitry Stogov
532b02cd19 Implemented registry cache that prevent registry lookup on each request. In case of modification of corresponding registry-tree PHP will reload it automatic. 2006-11-10 11:42:07 +00:00
Dmitry Stogov
a930751112 Faster and better licensed implementation 2006-11-10 10:10:38 +00:00
Ilia Alshanetsky
126be8ec7c Added missing API declarations. 2006-11-10 01:28:59 +00:00
Ilia Alshanetsky
ddae41877f Added missing PHPAPI declaration 2006-11-09 20:01:41 +00:00
Dmitry Stogov
25f01e8ec3 Fixed tests 2006-11-09 08:29:18 +00:00
Ilia Alshanetsky
d6b3b73490 Fixed tests 2006-11-07 20:24:38 +00:00
Ilia Alshanetsky
07cdfefdee Fixed bug #39350 (crash with implode("\n", array(false))). 2006-11-06 17:21:05 +00:00
Dmitry Stogov
82f89748a4 Windows doesn't have chown(). Remove unused function and reference to undeclared macro VCWD_CHOWN(). 2006-11-06 14:54:52 +00:00
Rasmus Lerdorf
cea64d52fa data: and php:stdin/input allow_url_include checks 2006-11-05 20:08:58 +00:00
Hannes Magnusson
b11b08e987 MFH: fix parameter parsing in getrusage() 2006-11-03 15:48:39 +00:00
Hannes Magnusson
050f94f746 MFH: Fix double "wron param count" messages 2006-11-03 14:46:48 +00:00
Hannes Magnusson
4f4e724b1b MFH: Remove SKIPIF 2006-11-03 14:17:40 +00:00
Ilia Alshanetsky
bd2ab7bc15 Fixed bug #39215 (Inappropriate close of stdin/stdout/stderr). 2006-11-03 13:34:19 +00:00
Ilia Alshanetsky
3a533934c7 Added missing boundary checks. 2006-11-01 01:55:11 +00:00
Antony Dovgal
0cf7b1012f add new test by Pierre 2006-10-19 12:07:07 +00:00
Antony Dovgal
0ebfbfe791 MFH: initialize optional vars 2006-10-16 19:27:57 +00:00
Hannes Magnusson
b3a914aca8 Fix test (bug#39097) 2006-10-15 13:43:45 +00:00
Hannes Magnusson
e4bdd6fcba Added missing API function declaration. 2006-10-13 09:34:34 +00:00
Ilia Alshanetsky
bc59416ff2 Fixed bug #38934 (move_uploaded_file() cannot read uploaded file outside of
open_basedir).
2006-10-13 01:42:20 +00:00
Sara Golemon
adf31588d2 MFH(r-1.96) Bugfix#38649 Optional param not initialized 2006-10-11 23:22:45 +00:00
Antony Dovgal
e20650616e add test 2006-10-11 14:57:52 +00:00
Antony Dovgal
14b168fcab MFH: check filter and class names for empty strings 2006-10-11 14:46:40 +00:00
Ilia Alshanetsky
a39201675f Catch empty strings right away. 2006-10-11 14:19:55 +00:00
Antony Dovgal
9b7ba01618 MFH: avoid reading str[-1], add warning when invalid format specified
add test
2006-10-11 13:15:30 +00:00
Antony Dovgal
1cc0339d40 MFH: fix crash when parsing invalid hostnames/IPs 2006-10-11 12:53:56 +00:00
Ilia Alshanetsky
7b77d536c3 Fixed bug #37262 (var_export() does not escape \0 character). 2006-10-09 18:08:34 +00:00