Commit Graph

97424 Commits

Author SHA1 Message Date
Xinchen Hui
81a7d52814 Folder marks 2016-08-02 20:08:15 +08:00
Xinchen Hui
70f79fd8b6 Optimized array_merge and cleanup 2016-08-02 20:02:23 +08:00
Xinchen Hui
87057858a0 Merge branch 'PHP-7.1' of git.php.net:/php-src into PHP-7.1
* 'PHP-7.1' of git.php.net:/php-src:
  prepare next
  fix php_version.h
2016-08-02 17:40:37 +08:00
Xinchen Hui
e730c8fc90 Optimized array_merge 2016-08-02 17:39:53 +08:00
Anatol Belski
45eadced70 Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  prepare next
2016-08-02 11:15:07 +02:00
Anatol Belski
5c51433e2a prepare next 2016-08-02 11:13:20 +02:00
Anatol Belski
ed863e45da Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  fix php_version.h
2016-08-02 11:08:21 +02:00
Anatol Belski
9f14920725 fix php_version.h 2016-08-02 11:06:33 +02:00
Xinchen Hui
fea2042a47 Optimized array_column (thanks to Benjamin Coutu) 2016-08-02 12:40:46 +08:00
Xinchen Hui
a15902fa71 fixed IS_REFERENCE handling 2016-08-02 11:05:51 +08:00
Xinchen Hui
f93061471b Make the expression more reasonble (by nikic) 2016-08-01 20:20:01 +08:00
Xinchen Hui
4d9195927a Optimized array_reverse 2016-08-01 20:11:08 +08:00
Anatol Belski
318102fc60 update NEWS 2016-07-31 15:01:45 +02:00
Anatol Belski
db9baae4fb Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  update NEWS
  Revert "upgraded to PCRE 8.39"
2016-07-31 15:00:18 +02:00
Anatol Belski
753e6eacd5 update NEWS 2016-07-31 14:58:46 +02:00
Anatol Belski
5f9df47ea8 Revert "upgraded to PCRE 8.39"
This reverts commit 2fba646837.

PCRE-8.39 throws weird valgrind backtraces on some systems, see
http://news.php.net/php.cvs/93494 . Those could be false positives
due to some changes in JIT, still i couldn't 100% ensure this.
Thus, better we continue to ship 8.38 bundled for now, and apply
patches, if needed.
2016-07-31 14:55:17 +02:00
Nikita Popov
0e52228d60 Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 18:36:09 +02:00
Nikita Popov
c4d35c3214 Merge branch 'PHP-5.6' into PHP-7.0 2016-07-30 18:36:00 +02:00
Nikita Popov
c9d3ff0c6e Revert "Fixed bug #71219"
This reverts commit 14d674442e.

I misread the discussion on the bug -- this is not the correct
fix. However the other proposed fix does not work either, so just
reverting for now.
2016-07-30 18:34:34 +02:00
Nikita Popov
510aba6276 Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 18:24:59 +02:00
Nikita Popov
9fe0398dad Merge branch 'PHP-5.6' into PHP-7.0 2016-07-30 18:24:14 +02:00
Nikita Popov
14d674442e Fixed bug #71219 2016-07-30 18:21:19 +02:00
Nikita Popov
7e8c4fcc40 Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 16:29:33 +02:00
Nikita Popov
dd7bea17bf Merge branch 'PHP-5.6' into PHP-7.0
Conflicts:
	ext/wddx/wddx.c
2016-07-30 16:29:10 +02:00
Nikita Popov
99613431b4 Add missing TSRMLS_FETCH() 2016-07-30 16:28:42 +02:00
Nikita Popov
f9be9b1a72 Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 16:08:30 +02:00
Nikita Popov
029f8e8777 Fix incorrect merge
Forgot to amend the merge fixes...
2016-07-30 16:07:54 +02:00
Nikita Popov
be836ea4fb Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 15:55:00 +02:00
Nikita Popov
1f67b4c24d Merge branch 'PHP-5.6' into PHP-7.0 2016-07-30 15:51:23 +02:00
Nikita Popov
e87ac688d5 Fixed bug #72142 2016-07-30 15:13:03 +02:00
Christoph M. Becker
9c2814313d Merge branch 'PHP-7.0' into PHP-7.1 2016-07-30 12:04:12 +02:00
Christoph M. Becker
e5940aa795 Merge branch 'PHP-5.6' into PHP-7.0 2016-07-30 12:01:29 +02:00
ju1ius
1d32b80903 fixes bad address given to onig_error_code_to_str
Closes bug #72710

(cherry picked from commit 0fb7eb6723)
2016-07-30 11:46:34 +02:00
Nikita Popov
ca82574d7c Fix invalid free on undef const in update_const()
Also clean up the control flow a bit -- move all unqualified
constant handling in one branch.
2016-07-30 00:37:01 +02:00
Nikita Popov
11e050920d Fix memory unsafety in array_walk()
Fixes bugs #61967, #62607, #69068, #70713.

The primary changes are:
a) Use the ht_iterator mechanism to ensure safety not only if the
   iterated array itself changes, but also if it is replaced (and
   potentially destroyed) entirely. We use the same semantics for
   behavior under modification as foreach-by-reference. In
   particular, we advance to the next element before processing it.
   If the iterated entity is exchanged we iterate the new one from
   the start. If it is not an array/object we warn and abort.
b) Always create a reference to the current value. Previously the
   code kept the value as a non-reference and updated it to the
   reference value produced by the user callback. However this is
   unsafe, as the array may have been reallocated in the meantime,
   so the previous value pointer is no longer value.
c) Around a recursive walk, incref the reference containing the
   array. This ensures that the location where the currently
   iterated value is stored cannot be freed.

One problem I was not able to solve is that we cannot decrement
the apply count if the array is exchanged during a recursive walk.
2016-07-30 00:15:32 +02:00
Nikita Popov
261c436d8c Merge branch 'PHP-7.0' into PHP-7.1 2016-07-29 19:08:15 +02:00
Nikita Popov
8a442a33c3 Fix ref handling in array_merge/replace_recursive()
As usual, if the reference has rc=1 it really isn't a reference.
2016-07-29 19:07:04 +02:00
Anatol Belski
5b6f793644 update NEWS 2016-07-29 17:33:40 +02:00
Anatol Belski
9b9aeb66bd add test for bug #72701 2016-07-29 17:23:39 +02:00
Anatol Belski
8033fb4044 Fixed bug #72701 mysqli_get_host_info() wrong output 2016-07-29 17:00:52 +02:00
Anatol Belski
fe8daf2a28 fix typo 2016-07-29 15:08:55 +02:00
Anatol Belski
d6f7020eaa add more errno handling 2016-07-29 15:05:41 +02:00
Anatol Belski
d8403aa019 set errno in ioutil access routine 2016-07-29 14:31:06 +02:00
Anatol Belski
6dbfd4287b move error check to right place
this only makes sense when length was passed
2016-07-29 13:33:58 +02:00
Anatol Belski
0596a2561b Merge branch 'PHP-7.0' into PHP-7.1
* PHP-7.0:
  document file cache fallback ini directive
2016-07-29 13:07:43 +02:00
Anatol Belski
1666e80cb9 document file cache fallback ini directive 2016-07-29 13:04:51 +02:00
Anatol Belski
41d172d20f fix and improve the ioutil cwd routine for nts
- move intermediate var to stack
- fix length calculation
- improve error code setting
2016-07-29 02:41:00 +02:00
Christoph M. Becker
09b5a453c1 Merge branch 'PHP-7.0' into PHP-7.1 2016-07-29 01:27:51 +02:00
Christoph M. Becker
293dd3d701 Merge branch 'PHP-5.6' into PHP-7.0
# Resolved conflicts:
#	ext/calendar/calendar.c
2016-07-29 01:26:15 +02:00
Christoph M. Becker
f67ccd4a7b Fix #71894: AddressSanitizer: global-buffer-overflow in zif_cal_from_jd
Julian days < 347998 denote invalid Jewish calendar dates, so
cal_from_jd($jd, CAL_JEWISH) and jdmonthname($jd, CAL_MONTH_JEWISH) should
actually fail. For BC we don't yet let them though, but we fix the OOB read
that happens in this case, and we also adjust cal_from_jd()'s return value
to have empty strings for "abbrevdayname" and "dayname" instead of "Sun"/
"Sunday" and NULL for "dow" instead of 0, which doesn't make any sense.
2016-07-29 01:04:21 +02:00