com php-src: Merge branch 'PHP-7.3' into PHP-7.4: NEWS ext/standard/array.c
| From: | Nikita Popov | Date: | Thu, 07 Nov 2019 10:17:14 +0000 |
| Subject: | com php-src: Merge branch 'PHP-7.3' into PHP-7.4: NEWS ext/standard/array.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-109204@lists.php.net to get a copy of this message | ||
Commit: aed4f6e8492d64de10c540dc57a30a995163ac3e
Author: Nikita Popov <nikita.ppv@gmail.com> Thu, 7 Nov 2019 11:17:14 +0100
Parents: 0988f6963420ab26b7804e080380b813ca79cfa8 8d2a9d8859db8c3b35e44ae55f0bdadeb594d872
Branches: PHP-7.4 master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=aed4f6e8492d64de10c540dc57a30a995163ac3e
Log:
Merge branch 'PHP-7.3' into PHP-7.4
* PHP-7.3:
Fixed bug #78759
Bugs:
https://bugs.php.net/78759
Changed paths:
MM NEWS
MM ext/standard/array.c
Diff:
diff --cc NEWS
index ae50a66bedc,8d540d620a1..f0247cbead0
--- a/NEWS
+++ b/NEWS
@@@ -1,26 -1,24 +1,27 @@@
PHP NEWS
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
-?? ??? ????, PHP 7.3.13
+?? ??? ????, PHP 7.4.0RC6
- Core:
- . Fixed bug #78787 (Segfault with trait overriding inherited private shadow
- property). (Nikita)
+ . Fixed bug #78768 (redefinition of typedef zend_property_info). (Nikita)
+ . Fixed bug #78788 (./configure generates invalid php_version.h). (max)
- Standard:
+ . Fixed bug #77930 (stream_copy_to_stream should use mmap more often).
+ (Nikita)
+ . Fixed bug #78759 (array_search in $GLOBALS). (Nikita)
-21 Nov 2019, PHP 7.3.12
+- OpenSSL:
+ . Fixed bug #78775 (TLS issues from HTTP request affecting other encrypted
+ connections). (Nikita)
+
+- Reflection:
+ . Fixed bug #78774 (ReflectionNamedType on Typed Properties Crash). (Nikita)
+
+31 Oct 2019, PHP 7.4.0RC5
- Core:
- . Fixed bug #78658 (Memory corruption using Closure::bindTo). (Nikita)
- . Fixed bug #78656 (Parse errors classified as highest log-level). (Erik
- Lundin)
- . Fixed bug #78752 (Segfault if GC triggered while generator stack frame is
- being destroyed). (Nikita)
- . Fixed bug #78689 (Closure::fromCallable() doesn't handle
- [Closure, '__invoke']). (Nikita)
+ .. Fixed bug #78226 (Unexpected __set behavior with typed properties). (Nikita)
- COM:
. Fixed bug #78694 (Appending to a variant array causes segfault). (cmb)
diff --cc ext/standard/array.c
index d44e5d50e74,300f7149323..ec0890478a3
--- a/ext/standard/array.c
+++ b/ext/standard/array.c
@@@ -1557,42 -1563,24 +1557,42 @@@ static inline void php_search_array(INT
ZEND_PARSE_PARAMETERS_END();
if (strict) {
- ZEND_HASH_FOREACH_KEY_VAL_IND(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
- ZVAL_DEREF(entry);
- if (fast_is_identical_function(value, entry)) {
- if (behavior == 0) {
- RETURN_TRUE;
- } else {
- if (str_idx) {
- RETVAL_STR_COPY(str_idx);
+ if (Z_TYPE_P(value) == IS_LONG) {
- ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
++ ZEND_HASH_FOREACH_KEY_VAL_IND(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
+ ZVAL_DEREF(entry);
+ if (Z_TYPE_P(entry) == IS_LONG && Z_LVAL_P(entry) == Z_LVAL_P(value)) {
+ if (behavior == 0) {
+ RETURN_TRUE;
} else {
- RETVAL_LONG(num_idx);
+ if (str_idx) {
+ RETVAL_STR_COPY(str_idx);
+ } else {
+ RETVAL_LONG(num_idx);
+ }
+ return;
}
- return;
}
- }
- } ZEND_HASH_FOREACH_END();
+ } ZEND_HASH_FOREACH_END();
+ } else {
- ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
++ ZEND_HASH_FOREACH_KEY_VAL_IND(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
+ ZVAL_DEREF(entry);
+ if (fast_is_identical_function(value, entry)) {
+ if (behavior == 0) {
+ RETURN_TRUE;
+ } else {
+ if (str_idx) {
+ RETVAL_STR_COPY(str_idx);
+ } else {
+ RETVAL_LONG(num_idx);
+ }
+ return;
+ }
+ }
+ } ZEND_HASH_FOREACH_END();
+ }
} else {
if (Z_TYPE_P(value) == IS_LONG) {
- ZEND_HASH_FOREACH_KEY_VAL(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
+ ZEND_HASH_FOREACH_KEY_VAL_IND(Z_ARRVAL_P(array), num_idx, str_idx, entry) {
if (fast_equal_check_long(value, entry)) {
if (behavior == 0) {
RETURN_TRUE;