]>
granicus.if.org Git - php/log
Dmitry Stogov [Tue, 17 Mar 2020 12:45:54 +0000 (15:45 +0300)]
Improved JIT for ZEND_ASSIGN
Nikita Popov [Tue, 17 Mar 2020 11:08:46 +0000 (12:08 +0100)]
Fix typos
Remi Collet [Tue, 17 Mar 2020 10:29:20 +0000 (11:29 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
bump verison to 7.2.30-dev
Remi Collet [Tue, 17 Mar 2020 10:29:03 +0000 (11:29 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
bump verison to 7.2.30-dev
Remi Collet [Tue, 17 Mar 2020 10:28:47 +0000 (11:28 +0100)]
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
bump verison to 7.2.30-dev
Remi Collet [Tue, 17 Mar 2020 10:28:34 +0000 (11:28 +0100)]
bump verison to 7.2.30-dev
Christoph M. Becker [Tue, 17 Mar 2020 10:15:48 +0000 (11:15 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix NEWS
Christoph M. Becker [Tue, 17 Mar 2020 10:11:15 +0000 (11:11 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix NEWS
Christoph M. Becker [Tue, 17 Mar 2020 10:08:45 +0000 (11:08 +0100)]
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
Fix NEWS
Christoph M. Becker [Tue, 17 Mar 2020 10:04:24 +0000 (11:04 +0100)]
Fix NEWS
Christoph M. Becker [Tue, 17 Mar 2020 10:00:48 +0000 (11:00 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Christoph M. Becker [Tue, 17 Mar 2020 09:58:58 +0000 (10:58 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Christoph M. Becker [Tue, 17 Mar 2020 09:56:47 +0000 (10:56 +0100)]
Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Christoph M. Becker [Tue, 17 Mar 2020 09:33:28 +0000 (10:33 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Fix #79283: Segfault in libmagic patch contains a buffer overflow
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
Christoph M. Becker [Tue, 17 Mar 2020 09:30:57 +0000 (10:30 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
[ci skip] Update NEWS
Fix test
Fix bug #79329 - get_headers should not accept \0
Fixed bug #79282
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
Stanislav Malyshev [Mon, 16 Mar 2020 00:55:28 +0000 (17:55 -0700)]
Fix test
Stanislav Malyshev [Mon, 16 Mar 2020 00:30:44 +0000 (17:30 -0700)]
Fix bug #79329 - get_headers should not accept \0
Stanislav Malyshev [Mon, 16 Mar 2020 00:26:00 +0000 (17:26 -0700)]
Fixed bug #79282
Christoph M. Becker [Mon, 2 Mar 2020 14:26:59 +0000 (15:26 +0100)]
Fix #79283: Segfault in libmagic patch contains a buffer overflow
To solve this, we properly calculate the required string length upfront
instead of allocating an oversized string (`len * 4 + 4`).
Christoph M. Becker [Thu, 12 Mar 2020 12:04:04 +0000 (13:04 +0100)]
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
We make sure that negative values are properly compared.
Stanislav Malyshev [Mon, 16 Mar 2020 02:35:01 +0000 (19:35 -0700)]
[ci skip] Update NEWS
Stanislav Malyshev [Mon, 16 Mar 2020 00:55:28 +0000 (17:55 -0700)]
Fix test
Stanislav Malyshev [Mon, 16 Mar 2020 00:30:44 +0000 (17:30 -0700)]
Fix bug #79329 - get_headers should not accept \0
Stanislav Malyshev [Mon, 16 Mar 2020 00:26:00 +0000 (17:26 -0700)]
Fixed bug #79282
Christoph M. Becker [Mon, 2 Mar 2020 14:26:59 +0000 (15:26 +0100)]
Fix #79283: Segfault in libmagic patch contains a buffer overflow
To solve this, we properly calculate the required string length upfront
instead of allocating an oversized string (`len * 4 + 4`).
Christoph M. Becker [Thu, 12 Mar 2020 12:04:04 +0000 (13:04 +0100)]
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
We make sure that negative values are properly compared.
Stanislav Malyshev [Mon, 16 Mar 2020 02:35:35 +0000 (19:35 -0700)]
[ci skip] Update NEWS
Stanislav Malyshev [Mon, 16 Mar 2020 00:55:28 +0000 (17:55 -0700)]
Fix test
Stanislav Malyshev [Mon, 16 Mar 2020 00:30:44 +0000 (17:30 -0700)]
Fix bug #79329 - get_headers should not accept \0
Stanislav Malyshev [Mon, 16 Mar 2020 00:26:00 +0000 (17:26 -0700)]
Fixed bug #79282
Christoph M. Becker [Thu, 12 Mar 2020 12:04:04 +0000 (13:04 +0100)]
Fix #79371: mb_strtolower (UTF-32LE): stack-buffer-overflow
We make sure that negative values are properly compared.
Dmitry Stogov [Mon, 16 Mar 2020 21:25:47 +0000 (00:25 +0300)]
Store informaton about class
Dmitry Stogov [Mon, 16 Mar 2020 20:08:07 +0000 (23:08 +0300)]
Fixed recording classes of object references
Nikita Popov [Mon, 16 Mar 2020 17:37:01 +0000 (18:37 +0100)]
Fix assertion when (real) is used
And bring back a test for it...
Nikita Popov [Mon, 16 Mar 2020 14:39:02 +0000 (15:39 +0100)]
Slightly deduplicate code
This code is the same in both branches, extract it.
Nikita Popov [Mon, 16 Mar 2020 14:07:59 +0000 (15:07 +0100)]
Remove "safe" argument from ZVAL_PTR_DTOR
This is no longer used
Nikita Popov [Mon, 16 Mar 2020 14:04:50 +0000 (15:04 +0100)]
Fix typos
Nikita Popov [Mon, 16 Mar 2020 12:02:16 +0000 (13:02 +0100)]
Merge EX variants of INFO macros
Nikita Popov [Mon, 16 Mar 2020 11:32:40 +0000 (12:32 +0100)]
Merge EX variants of RANGE macros
Only need to create the ssa_op variable in range inference...
Nikita Popov [Mon, 16 Mar 2020 11:23:55 +0000 (12:23 +0100)]
Merge zend_may_throw(_ex)
Explicitly pass ssa_op in the places that don't do so yet.
Nikita Popov [Mon, 16 Mar 2020 11:01:50 +0000 (12:01 +0100)]
Remove unnecessary cast
Máté Kocsis [Mon, 16 Mar 2020 09:27:48 +0000 (10:27 +0100)]
Fix ZPP of MultipleIterator::detachIterator() and MultipleIterator::containsIterator()
Máté Kocsis [Sat, 14 Mar 2020 19:16:19 +0000 (20:16 +0100)]
Add stubs for SplObjectStorage and MultipleIterator
Closes GH-5267
Máté Kocsis [Sat, 14 Mar 2020 18:26:20 +0000 (19:26 +0100)]
Add stubs for SplHeap and SplPriorityQueue
Closes GH-5266
Philipp Tanlak [Thu, 13 Feb 2020 15:23:01 +0000 (16:23 +0100)]
Add str_contains() function
RFC: https://wiki.php.net/rfc/str_contains
Closes GH-5179.
Nikita Popov [Mon, 16 Mar 2020 09:32:39 +0000 (10:32 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Don't specify ports in socket_export_stream-4.phpt
Nikita Popov [Mon, 16 Mar 2020 09:32:04 +0000 (10:32 +0100)]
Don't specify ports in socket_export_stream-4.phpt
Let the system pick a free port instead...
Stanislav Malyshev [Mon, 16 Mar 2020 02:35:26 +0000 (19:35 -0700)]
[ci skip] Update NEWS
Stanislav Malyshev [Mon, 16 Mar 2020 00:55:28 +0000 (17:55 -0700)]
Fix test
Stanislav Malyshev [Mon, 16 Mar 2020 00:30:44 +0000 (17:30 -0700)]
Fix bug #79329 - get_headers should not accept \0
Stanislav Malyshev [Mon, 16 Mar 2020 00:26:00 +0000 (17:26 -0700)]
Fixed bug #79282
Christoph M. Becker [Sun, 15 Mar 2020 14:02:10 +0000 (15:02 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix typo in php.ini comment
Christoph M. Becker [Sun, 15 Mar 2020 14:01:23 +0000 (15:01 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix typo in php.ini comment
Jacob Dreesen [Sun, 15 Mar 2020 13:11:40 +0000 (14:11 +0100)]
Fix typo in php.ini comment
Dmitry Stogov [Fri, 13 Mar 2020 22:29:46 +0000 (01:29 +0300)]
Emit warning about type narrowing for tracing JIT as well
Dmitry Stogov [Fri, 13 Mar 2020 22:17:45 +0000 (01:17 +0300)]
Fixed RC inference for ZEND_ASSIGN_STATIC_PROP and removed useless checks during RC inference
Dmitry Stogov [Fri, 13 Mar 2020 19:11:07 +0000 (22:11 +0300)]
Tracing JIT (it doesn't support register allocation yet)
Use opcache.jit=1255 to swith it on (the third digit 5 really matters)
Use opcache.jit_debug=0xff001 to see how it works and what code it generates
Nikita Popov [Fri, 13 Mar 2020 15:25:28 +0000 (16:25 +0100)]
Accept const op_array in zend_build_call_map
Nikita Popov [Fri, 13 Mar 2020 12:11:42 +0000 (13:11 +0100)]
Add assertions for DIM_W/RW uses
The result should be used only once and on the directly next opline,
otherwise it may not be safe. Add some assertions to that effect.
Nikita Popov [Fri, 13 Mar 2020 11:45:02 +0000 (12:45 +0100)]
Also remove dead arguments
Nikita Popov [Fri, 13 Mar 2020 11:26:18 +0000 (12:26 +0100)]
Remove dead type narrowing code
Rename handle_type_narrowing() to clarify what it does, and
remove dead code for resetting dependent vars.
Dmitry Stogov [Fri, 13 Mar 2020 08:42:07 +0000 (11:42 +0300)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Check asserts early
identation fix
Call global code of preloaded script in global context
Avoid "Anonymous class wasn't preloaded" error by lazely loading of not preloaded part of a preloaded script
Dmitry Stogov [Thu, 12 Mar 2020 19:26:30 +0000 (22:26 +0300)]
Check asserts early
Dmitry Stogov [Thu, 12 Mar 2020 19:26:16 +0000 (22:26 +0300)]
identation fix
Dmitry Stogov [Thu, 12 Mar 2020 19:19:47 +0000 (22:19 +0300)]
Call global code of preloaded script in global context
George Peter Banyard [Fri, 28 Feb 2020 11:13:03 +0000 (12:13 +0100)]
Remove deprecated (real) cast
Closes GH-5220
Dmitry Stogov [Thu, 12 Mar 2020 13:31:24 +0000 (16:31 +0300)]
Avoid "Anonymous class wasn't preloaded" error by lazely loading of not preloaded part of a preloaded script
Nikita Popov [Wed, 11 Mar 2020 20:15:28 +0000 (21:15 +0100)]
Update Unicode tables to 13.0.0
Christoph M. Becker [Thu, 12 Mar 2020 10:28:39 +0000 (11:28 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix #79199: curl_copy_handle() memory leak
Christoph M. Becker [Thu, 12 Mar 2020 10:27:30 +0000 (11:27 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix #79199: curl_copy_handle() memory leak
Christoph M. Becker [Wed, 11 Mar 2020 17:29:40 +0000 (18:29 +0100)]
Fix #79199: curl_copy_handle() memory leak
`curl_copy_handle()` already registers a new resource, so we must not
increase the refcount of the original resource.
Christoph M. Becker [Thu, 12 Mar 2020 09:57:14 +0000 (10:57 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix #61597: SXE properties may lack attributes and content
Christoph M. Becker [Thu, 12 Mar 2020 09:53:22 +0000 (10:53 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix #61597: SXE properties may lack attributes and content
Christoph M. Becker [Sat, 7 Mar 2020 10:20:06 +0000 (11:20 +0100)]
Fix #61597: SXE properties may lack attributes and content
We must not treat a node as string if it has attributes, unless it is
an entity declaration which is always treated as string by simplexml.
Dmitry Stogov [Thu, 12 Mar 2020 08:45:05 +0000 (11:45 +0300)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Export FFI::__BIGGEST_ALIGNMENT__
Dmitry Stogov [Thu, 12 Mar 2020 08:43:01 +0000 (11:43 +0300)]
Export FFI::__BIGGEST_ALIGNMENT__
Dmitry Stogov [Thu, 12 Mar 2020 08:41:12 +0000 (11:41 +0300)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Allow to fetch function address
Dmitry Stogov [Thu, 12 Mar 2020 08:40:48 +0000 (11:40 +0300)]
Allow to fetch function address
Xinchen Hui [Thu, 12 Mar 2020 07:45:07 +0000 (15:45 +0800)]
Merge branch 'PHP-7.4'
Xinchen Hui [Thu, 12 Mar 2020 07:43:15 +0000 (15:43 +0800)]
Folder mark missed
Dmitry Stogov [Wed, 11 Mar 2020 12:29:58 +0000 (15:29 +0300)]
Export FFI::__BIGGEST_ALIGNMENT__
Dmitry Stogov [Wed, 11 Mar 2020 12:13:27 +0000 (15:13 +0300)]
Allow to fetch function address
Christoph M. Becker [Wed, 11 Mar 2020 10:32:46 +0000 (11:32 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix #78210: Invalid pointer address
Christoph M. Becker [Wed, 11 Mar 2020 10:30:59 +0000 (11:30 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix #78210: Invalid pointer address
Christoph M. Becker [Wed, 11 Mar 2020 09:16:04 +0000 (10:16 +0100)]
Fix #78210: Invalid pointer address
This is actually about three distinct issues:
* If an empty string is passed as $address to `stream_socket_sendto()`,
the `sa` is not initialized, so we must not pass it as `addr` to
`php_stream_xport_sendto()`.
* On POSIX, `recvfrom()` truncates messages which are too long to fit
into the specified buffer (unless `MSG_PEEK` is given), discards the
excessive bytes, and returns the buffer length. On Windows, the same
happens, but `recvfrom()` returns `SOCKET_ERROR` with the error code
`WSAEMSGSIZE`. We have to catch this for best POSIX compatibility.
* In `php_network_parse_network_address_with_port()`, we have to zero
`in6` (not only its alias `sa`) to properly support IPv6.
Co-Authored-By: Nikita Popov <nikita.ppv@googlemail.com>
Christoph M. Becker [Wed, 11 Mar 2020 07:57:17 +0000 (08:57 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fix #79364: When copy empty array, next key is unspecified
Christoph M. Becker [Wed, 11 Mar 2020 07:55:11 +0000 (08:55 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fix #79364: When copy empty array, next key is unspecified
Christoph M. Becker [Tue, 10 Mar 2020 15:12:53 +0000 (16:12 +0100)]
Fix #79364: When copy empty array, next key is unspecified
We must not forget to keep the `nNextFreeElement` when duplicating
empty arrays.
Nikita Popov [Tue, 10 Mar 2020 15:54:17 +0000 (16:54 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Check for sys/auxv.h before using it.
Peter Seiderer [Mon, 9 Mar 2020 14:36:48 +0000 (15:36 +0100)]
Check for sys/auxv.h before using it.
Fixes aarch64 compile with uclibc-ng (does not provide
sys/auxv.h header file).
Closes GH-5248.
Signed-off-by: Peter Seiderer <ps.report@gmx.net>
Nikita Popov [Tue, 10 Mar 2020 15:49:17 +0000 (16:49 +0100)]
Fixed bug #75902
Don't special-case nested arrays/objects in str_replace(), instead
perform a string cast on them as well. For arrays, this will always
result in the usual conversion warning.
This behavior is consistent with preg_replace(). If we didn't want
to cast the array to string here, we should instead perform the
replacement recursively. Silently copying it is just confusing.
Nikita Popov [Tue, 10 Mar 2020 15:17:32 +0000 (16:17 +0100)]
Enable better trait conflict error message
I don't think there is any reason to disable this anymore,
at least all the messages generated in tests look correct and
more useful.
Nikita Popov [Tue, 3 Mar 2020 13:31:09 +0000 (14:31 +0100)]
Require non-absolute trait method refs to be unambiguous
Currently, when writing something like
class X {
use T1, T2 {
func as otherFunc;
}
function func() {}
}
where both T1::func() and T2::func() exist, we will simply assume
that func refers to T1::func(). This is surprising, and it doesn't
really make sense that this particular method gets picked.
This commit validates that non-absolute method references are
unambiguous, i.e. refer to exactly one method. If there is
ambiguity, it is required to write T1::func as otherFunc or
similar.
Closes GH-5232.
Máté Kocsis [Fri, 6 Mar 2020 09:01:10 +0000 (10:01 +0100)]
Add some stubs for SPL
Closes GH-5245
Máté Kocsis [Thu, 5 Mar 2020 20:12:59 +0000 (21:12 +0100)]
Perform some maintenance work on the XSL extension
Added stubs, fixed some ZPP, and changed PHP_FALIASes to PHP_METHODs.
Closes GH-5241
Christoph M. Becker [Mon, 9 Mar 2020 21:53:23 +0000 (22:53 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Enclose INI values containing {TMP} in quotes
Christoph M. Becker [Mon, 9 Mar 2020 21:51:11 +0000 (22:51 +0100)]
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Enclose INI values containing {TMP} in quotes
Christoph M. Becker [Mon, 9 Mar 2020 16:58:36 +0000 (17:58 +0100)]
Enclose INI values containing {TMP} in quotes
At least on Windows, the temporary directory may contain tilde signs,
which would result in an INI parse error.
Nikita Popov [Mon, 9 Mar 2020 15:17:02 +0000 (16:17 +0100)]
Improve type inference for COALESCE
Place a pi node on the non-null edge to remove a spurious
undef/null type.
Additionally, adjust the profitability heuristic to be more
accurate if the "other predecessor" writes to the variable.
Ideally this should not just consider the direct predecessors,
but it's sufficient for this case.
This partially addresses bug #79353 by removing the discrepancy
between ?? and ??=.
Nikita Popov [Mon, 9 Mar 2020 14:01:48 +0000 (15:01 +0100)]
Merge branch 'PHP-7.4'
* PHP-7.4:
Fixed bug #79357