1
0
mirror of https://github.com/php/php-src.git synced 2026-04-24 08:28:26 +02:00
Commit Graph

12051 Commits

Author SHA1 Message Date
Nikita Popov bbdff7ea24 Sync convert_to_null with VM cast behavior
Do not call cast_object, this is useless and we haven't been doing
it in the VM as of 7.0.
2016-09-04 12:36:16 +02:00
Anatol Belski edc4de58b7 Merge branch 'PHP-7.1'
* PHP-7.1:
  fix useless assignment
  avoid needless function call
  remove useless assignment
  remove unused assignment
  rewrite the getcwd part
  fix leak
  fix unused assignment
  remove duplicated symbol
2016-09-01 23:54:33 +02:00
Anatol Belski 0382a64fdf remove unused assignment 2016-09-01 23:45:31 +02:00
Anatol Belski ac82a34185 rewrite the getcwd part
Also fixes a possible memory leak. Still not ideal, as seems CWD
longer than MAX_PATH is still not supported. But a heap allocation
is not needed anyway, as MAXPATHLEN value is the maximum supported.
2016-09-01 23:45:31 +02:00
Anatol Belski 0a50cbabf6 fix unused assignment 2016-09-01 23:45:31 +02:00
Anatol Belski c563db6b44 Merge branch 'PHP-7.1'
* PHP-7.1:
  Update NEWS
  Implement \ArgumentCountError exception
2016-08-31 12:07:38 +02:00
Davey Shafik 12ee17d5e0 Implement \ArgumentCountError exception 2016-08-30 19:35:56 -07:00
Dmitry Stogov 6318c80347 Merge branch 'PHP-7.1'
* PHP-7.1:
  Fixed bug #72944 (Null pointer deref in zval_delref_p).
2016-08-29 12:15:37 +03:00
Dmitry Stogov b5bab0fce8 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fixed bug #72944 (Null pointer deref in zval_delref_p).
2016-08-29 12:07:54 +03:00
Dmitry Stogov b66039db33 Fixed bug #72944 (Null pointer deref in zval_delref_p). 2016-08-29 12:02:50 +03:00
Xinchen Hui 727571c630 Merge branch 'PHP-7.1'
* PHP-7.1:
  Fixed bug #72936 (Zend API's zend_symtable_str_update() asserts key should end with '\0')
2016-08-29 00:11:09 +08:00
Xinchen Hui 01701912c7 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fixed bug #72936 (Zend API's zend_symtable_str_update() asserts key should end with '\0')
2016-08-29 00:10:57 +08:00
Xinchen Hui 986d0f87ec Fixed bug #72936 (Zend API's zend_symtable_str_update() asserts key should end with '\0') 2016-08-29 00:10:31 +08:00
Anatol Belski f407707bd6 Merge branch 'PHP-7.1'
* PHP-7.1:
  fix leak
  add parentheses
  fix clang compat
  fix leak
2016-08-27 22:30:06 +02:00
Anatol Belski d58202853d fix leak 2016-08-27 22:24:24 +02:00
Xinchen Hui 5ac49731cf Merge branch 'PHP-7.1'
* PHP-7.1:
  Fixed bug #72943 (assign_dim on string doesn't reset hval)
2016-08-26 18:33:10 +08:00
Xinchen Hui 557f1ccf0c Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fixed bug #72943 (assign_dim on string doesn't reset hval)

Conflicts:
	Zend/zend_execute.c
2016-08-26 18:32:54 +08:00
Xinchen Hui c67fa3c91d Fixed bug #72943 (assign_dim on string doesn't reset hval) 2016-08-26 18:30:08 +08:00
Xinchen Hui aefd3e4d8b Merge branch 'PHP-7.1'
* PHP-7.1:
  Remove redundant \t
2016-08-25 13:29:55 +08:00
Xinchen Hui 38f7d595c0 Remove redundant \t 2016-08-25 13:29:22 +08:00
Dmitry Stogov 0e3e3ec7b6 Merge branch 'PHP-7.1'
* PHP-7.1:
  Added tests and NEWS entry Fixed bug #72598 (Reference is lost after array_slice())
2016-08-23 12:16:36 +03:00
Dmitry Stogov 62ab40bc96 Added tests and NEWS entry
Fixed bug #72598 (Reference is lost after array_slice())
2016-08-23 12:14:31 +03:00
Dmitry Stogov 93b8592092 Merge branch 'PHP-7.1'
* PHP-7.1:
  call_user_func(_array): Don't abort on reference warning
2016-08-23 10:56:55 +03:00
Nikita Popov 906456c410 call_user_func(_array): Don't abort on reference warning
Change zend_call_function() to not abort the call if a non-reference
is passed to a reference argument. The usual warning will still be
thrown, but the call will proceed as usual.
2016-08-23 10:29:15 +03:00
Xinchen Hui 9121c872e9 Merge branch 'PHP-7.1'
* PHP-7.1:
  This is unecessary for 7.1 (IS_ERROR is an internal type)
  Fixed bug  #72911 (Memleak in zend_binary_assign_op_obj_helper)
  Fixed bug #72907 (null pointer deref, segfault in gc_remove_zval_from_buffer (zend_gc.c:260))
2016-08-21 17:40:45 +08:00
Xinchen Hui e849e65d89 This is unecessary for 7.1 (IS_ERROR is an internal type) 2016-08-21 17:40:10 +08:00
Xinchen Hui e572035ecf Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  Fixed bug  #72911 (Memleak in zend_binary_assign_op_obj_helper)
  Fixed bug #72907 (null pointer deref, segfault in gc_remove_zval_from_buffer (zend_gc.c:260))
2016-08-21 17:39:52 +08:00
Xinchen Hui 0476bb1de5 Fixed bug #72911 (Memleak in zend_binary_assign_op_obj_helper) 2016-08-21 17:38:03 +08:00
Aaron Piotrowski 83bdcf075b Merge branch 'PHP-7.1'
# Conflicts:
#	NEWS
#	UPGRADING
2016-08-21 00:34:00 -05:00
Aaron Piotrowski 08c5d77027 Revert "Fix closure tests using ReflectionType::__toString()"
This reverts commit 6fcedc96fb.
2016-08-20 23:26:01 -05:00
Kalle Sommer Nielsen 5b30f08809 Fixed master build, decls first please! 2016-08-17 20:33:07 +02:00
Kalle Sommer Nielsen 447e57a1e1 Fixed 7.1 build, decls first please! 2016-08-17 20:26:32 +02:00
Kalle Sommer Nielsen 8a1fbdda43 Fixed C89 build 2016-08-17 13:43:50 +02:00
Xinchen Hui 660d8f1622 Merge branch 'PHP-7.1'
* PHP-7.1: (49 commits)
  Update NEWs
  Update NEWs
  Unused label
  Fixed bug #72853 (stream_set_blocking doesn't work)
  fix test
  Bug #72663 - part 3
  Bug #72663 - part 2
  Bug #72663 - part 1
  Update NEWS
  BLock test with memory leak
  fix tests
  Fix TSRM build
  Fix bug #72850 - integer overflow in uuencode
  Fixed bug #72849 - integer overflow in urlencode
  Fix bug #72848 - integer overflow in quoted_printable_encode caused heap corruption
  Fix bug #72838 - 	Integer overflow lead to heap corruption in sql_regcase
  Fix bug #72837 - integer overflow in bzdecompress caused heap corruption
  Fix bug #72836 - integer overflow in base64_decode caused heap corruption
  Fix for bug #72807 - do not produce strings with negative length
  Fix for bug #72790 and bug #72799
  ...
2016-08-17 17:15:11 +08:00
Xinchen Hui ce6ad9bdd9 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0: (48 commits)
  Update NEWs
  Unused label
  Fixed bug #72853 (stream_set_blocking doesn't work)
  fix test
  Bug #72663 - part 3
  Bug #72663 - part 2
  Bug #72663 - part 1
  Update NEWS
  BLock test with memory leak
  fix tests
  Fix TSRM build
  Fix bug #72850 - integer overflow in uuencode
  Fixed bug #72849 - integer overflow in urlencode
  Fix bug #72848 - integer overflow in quoted_printable_encode caused heap corruption
  Fix bug #72838 - 	Integer overflow lead to heap corruption in sql_regcase
  Fix bug #72837 - integer overflow in bzdecompress caused heap corruption
  Fix bug #72836 - integer overflow in base64_decode caused heap corruption
  Fix for bug #72807 - do not produce strings with negative length
  Fix for bug #72790 and bug #72799
  Fix bug #72730 - imagegammacorrect allows arbitrary write access
  ...

Conflicts:
	ext/standard/var_unserializer.c
2016-08-17 17:14:30 +08:00
Stanislav Malyshev 75d7666968 Merge branch 'PHP-7.0.10' into PHP-7.0
* PHP-7.0.10:
  Fix bug #72749: wddx_deserialize allows illegal memory access
  Fixed bug #72627: Memory Leakage In exif_process_IFD_in_TIFF
  fix tests
  Fix bug#72697 - select_colors write out-of-bounds
  Fix bug #72708 - php_snmp_parse_oid integer overflow in memory allocation
  Fix bug #72730 - imagegammacorrect allows arbitrary write access
  Fix bug #72750: wddx_deserialize null dereference
  Fix bug #72771: ftps:// opendir wrapper is vulnerable to protocol downgrade attack
  fix tests
  add missing skipif section
  Fix for bug #72790 and bug #72799
  Fix bug #72837 - integer overflow in bzdecompress caused heap corruption
  Fix bug #72742 - memory allocator fails to realloc small block to large one
  Use size_t for path length
  Check for string overflow
  Fix for bug #72782: mcrypt accepts only ints, so don't pass anything else
  Fix bug #72674 - check both curl_escape and curl_unescape
2016-08-16 23:52:22 -07:00
Stanislav Malyshev f8a75d4eee Merge branch 'PHP-7.0' into PHP-7.0.10
* PHP-7.0: (34 commits)
  Fix URL rewriter partially
  Support "git worktree"
  Add NEWS
  Fix ASSERT logic
  Bugfix 72791: fix memory leak in PDO persistent connections
  Don't copy mime types in CLI server
  Remove obsolete Id tags
  Bump version in OCI8 test
  Fixed bug #72788 (Invalid memory access when using persistent PDO connection)
  Remove typo'd commit
  Fix bug 72788: Invalid memory access when database_object_handle is undefined. Also fix memory leak in dbh_free when using persistent PDO connections.
  Replace dead branch with ZEND_ASSERT()
  Add test for bug #69107: finfo no longer detects PHP files
  Fix bug #55451
  Fix stream_socket_enable_crypto() test
  Remove old $Id$ tags
  Sync with 7.1 branch changes from Nikita & Dimitri to keep OCI8 code identical
  Fix bug #72524 (Binding null values triggers ORA-24816 error)
  Fix the fix (Nikita), thanks!
  Check the return value of dbconvert() in mssql_guid_string(), as it may return -1 in case the conversion failed. In that case false is returned.
  ...

Conflicts:
	ext/standard/ftp_fopen_wrapper.c
2016-08-16 23:50:42 -07:00
Nikita Popov 339cafa035 Merge branch 'PHP-7.1' 2016-08-16 21:07:46 +02:00
Nikita Popov 7384fcff0a Merge branch 'PHP-7.0' into PHP-7.1 2016-08-16 21:05:57 +02:00
Nikita Popov e2230c17d3 Fix bug #72854 2016-08-16 21:05:30 +02:00
Aaron Piotrowski 40dcc1b57c Merge branch 'PHP-7.1' 2016-08-16 13:06:06 -05:00
Aaron Piotrowski 6fcedc96fb Fix closure tests using ReflectionType::__toString() 2016-08-16 13:05:51 -05:00
Nikita Popov 70eeafa326 Merge branch 'PHP-7.1' 2016-08-16 15:51:32 +02:00
Nikita Popov ba09a520d2 Cleanup parameter/return type checking code
a) Extract all the logic for error message formatting into a separate
function that is reused for everything.
b) Extract the logic for whether a value matches a type into two
functions, one for user types, one for internal ones.

This tries to fight the increasing code duplication in the type
checking code, whether everything was repeated at least four times
and parts of the error message handling were repeated in dozens of
branches.
2016-08-16 15:48:33 +02:00
Nikita Popov befca6a283 Merge branch 'PHP-7.1' 2016-08-16 12:43:46 +02:00
Nikita Popov 1397f754c8 Fix handling of qualified nullable parameter types
compile_typename() can't deal with TYPE_NULLABLE flags, drop it
beforehand.
2016-08-16 12:43:17 +02:00
Dmitry Stogov ff06588130 Fixed use after free 2016-08-16 11:44:22 +03:00
Nikita Popov 89f6377971 Return true for is_object() on Incomplete_Class 2016-08-15 23:13:09 +02:00
Stanislav Malyshev c2a13ced42 Fix bug #72742 - memory allocator fails to realloc small block to large one 2016-08-14 19:08:59 -07:00
Xinchen Hui 7ec53e8ff2 Merge branch 'PHP-7.1'
* PHP-7.1:
  Update NEWs
  Fixed bug #72813 (Segfault with __get returned by ref)
  Fix URL rewriter partially
2016-08-12 16:37:14 +08:00