Commit Graph

10438 Commits

Author SHA1 Message Date
Anatol Belski
abfda3de99 Update NEWS [ci skip] 2018-10-03 18:48:40 +02:00
Nikita Popov
83e2b9e220 Fixed bug #76946 2018-09-28 19:15:19 +02:00
Sara Golemon
69c1b619c9
Bump versions for 7.1.24-dev 2018-09-28 11:31:22 -04:00
Nikita Popov
45cdcb2d0b Fixed bug #76846 2018-09-28 12:56:47 +02:00
Christoph M. Becker
9cbe1283f7 Fix #66828: iconv_mime_encode Q-encoding longer than it should be
Before the fix for bug 48289 has been applied, the algorithm to
construct a Q-encoded-word has been optimistic, i.e. try to encode as
many bytes that *may* fit in the remaining space, calculate the actual
length of the Q-encoded word, and if it's too long, try again with a
reduced size.  However, the fix for the mentioned bug replaced this by
a pessimistic algorithm, which always terminates[1] the for loop[2]
during the first iteration (which renders the following 3 lines as dead
code), and as such easily produces unnecessarily short encoded-words.
Instead the proper fix for the bug would have been to make sure that
`out_size` is always decremented, if the space isn't sufficient for the
encoded-word.

[1] <https://github.com/php/php-src/blob/php-7.3.0beta3/ext/iconv/iconv.c#L1421>
[2] <https://github.com/php/php-src/blob/php-7.3.0beta3/ext/iconv/iconv.c#L1360>
2018-09-22 15:20:20 +02:00
Nikita Popov
294fb83ee8 Fixed bug #76901
get_method() may modify the object pointer passed to it if method
forwarding is used. In this case we do not want to modify the
passed zval, so make sure that we copy the object into a temporary
first.
2018-09-19 09:37:04 +02:00
Manabu Matsui
ab6c45f524 Fix bug #75533: array_reduce is slow when $carry is large array 2018-09-18 20:49:59 +02:00
Pierrick Charron
3bb218a0a7 Fix 76480: Use curl_multi_wait() so that timeouts are respected 2018-09-17 20:28:44 -04:00
Christoph M. Becker
90d863898c Fix #75273: php_zlib_inflate_filter() may not update bytes_consumed
Whenever we return with `PSFS_PASS_ON`, we need to update
`bytes_consumed` to not mislead the caller.  Instead of fixing the
respective `if` clauses, we eschew the early bail-outs to simplify the
code a bit.
2018-09-08 19:01:36 +02:00
Christoph M. Becker
c0a389a927 Fix #74454: Wrong exception being thrown when using ReflectionMethod
If zend_throw_exception_ex() already threw an exception, we should not
throw again.
2018-09-05 15:05:19 +02:00
Ville Hukkamaki
0f724453c0
Fix bug #74764 and add a test case 2018-09-04 11:12:04 +02:00
Anatol Belski
e58690a26d [ci skip] Update NEWS 2018-09-04 11:01:24 +02:00
Ville Hukkamaki
742783c3ee Fixed bug #73457
Correctly report errors when opening FTP data connection.
2018-09-04 04:53:38 +02:00
Christoph M. Becker
2677d43850 Fix #75696: posix_getgrnam fails to print details of group
According to the POSIX specification of `getgrnam_r()` the result of
`sysconf(_SC_GETGR_R_SIZE_MAX)` is an initial value suggested for the
size of the buffer, and `ERANGE` signals that insufficient storage was
supplied.  So if we get `ERANGE`, we try again with a buffer twice as
big, and so on, instead of failing.
2018-09-01 14:25:59 +02:00
Sara Golemon
5fee4e7108
Prep for 7.1.23 2018-08-29 12:41:05 -04:00
Christoph M. Becker
efb86aef12 Fix #68180: iconv_mime_decode can return extra characters in a header
Basically, the algorithm to append a converted string to an existing
`smart_str` works by increasing the `smart_str` buffer, to let `iconv`
convert characters until there is no more space, to set the new length
of the `smart_str` and to repeat until there is no more input.

Formerly, the new length calculation has been wrong, though, since we
would have to take the old `out_len` into account (`buf_growth -
old_out_len - out_len`).  However, since there is no need to take the
old `out_len` into account when increasing the `smart_str` buffer, we
can simplify the fix, avoiding an additional variable.
2018-08-26 13:18:35 +02:00
Christoph M. Becker
e29c946c29 Fix #60494: iconv_mime_decode does ignore special characters
We must not ignore erroneous characters in mime headers, but rather let
iconv_mime_decode() fail in this case, issuing the usual notice
regarding illegal characters.
2018-08-25 17:40:39 +02:00
Christoph M. Becker
8754d44167 Fix #63839: iconv_mime_decode_headers function is skipping headers
We have to cater to the possibility that `=?` is not the start of an
encoded-word, but rather a literal `=?`.  If a line break is found
while we're still looking for the charset, we can safely assume that
it's a literal `=?`, and act accordingly.
2018-08-25 14:51:13 +02:00
Christoph M. Becker
6e1980e152 Fix #55146: iconv_mime_decode_headers() skips some headers
If we're expecting the start of an encoded word (`=?`), but instead of
the question mark get a line break (CR or LF), we must not append it to
the `pretval`.
2018-08-25 14:40:07 +02:00
Christoph M. Becker
32a728d351 Fix #68825: Exception in DirectoryIterator::getLinkTarget()
intern->file_name may not have been properly set when
DirectoryIterator::getLinkTarget() is called, so we make sure it is
before using it.
2018-08-22 15:37:02 +02:00
Christoph M. Becker
70b2fca220 Fix #76778: array_reduce leaks memory if callback throws exception
We have to release the result variable in the error case, too.
2018-08-22 13:40:24 +02:00
Ville Hukkamaki
cf2fc66b02 Fixed bug #76777 and added test
Set undefined values to null rather than undefined.
2018-08-22 12:51:06 +02:00
Jakub Zelenka
4c542e6c13 Fix bug #76705 (unusable ssl => peer_fingerprint in stream_context_create()) 2018-08-19 20:14:26 +01:00
Christoph M. Becker
4c448334bd Add regression test for bug #68175 2018-08-18 14:36:16 +02:00
Xinchen Hui
04c4854fdf Fixed bug #76754 (parent private constant in extends class memory leak) 2018-08-17 13:35:15 +08:00
Xinchen Hui
8c92442b49 Fixed bug #76747 (Opcache treats path containing "test.pharma.tld" as a phar file) 2018-08-16 13:56:20 +08:00
Tyson Andre
e20baee136 Fix arginfo for bzcompress
bzcompress() has 1 required parameter, not 2.

See http://php.net/manual/en/function.bzcompress.php or invoke
bzcompress with 1 parameter.
2018-08-13 15:59:08 +02:00
Anatol Belski
859f7fce1f Update NEWS [ci skip] 2018-08-13 09:11:57 +02:00
Peter Kokot
935625f1b8 [ci skip] Update NEWS 2018-08-06 09:41:38 +02:00
Peter Kokot
4d5edcb4ac [ci skip] Update NEWS 2018-08-06 06:17:45 +02:00
Peter Kokot
b4b14d2106 [ci skip] Update NEWS 2018-08-06 01:43:37 +02:00
Peter Kokot
169a98319a [ci skip] Update NEWS 2018-08-05 20:35:23 +02:00
Peter Kokot
fd0fc20d35 [ci skip] Update NEWS
Bug fix #76595 has been done after RC release and should go to
appropriate NEWS location then.
2018-08-04 16:16:07 +02:00
Christoph M. Becker
c00f5e6531 Fix #76704: mb_detect_order return value varies based on argument type
php_mb_parse_encoding_list() and php_mb_parse_encoding_array() are
supposed to return SUCCESS and FAILURE, not 1 and 0, respectively.
2018-08-04 12:51:57 +02:00
Peter Kokot
b71a503844 [ci skip] Update NEWS 2018-08-04 06:39:19 +02:00
Joe Watkins
74988eed99
bump version 2018-07-31 16:38:35 +02:00
Anatol Belski
2870178720 Update NEWS [ci skip] 2018-07-30 19:42:10 +02:00
Christoph M. Becker
ed7e3bc70a Fix #76665: SQLite3Stmt::bindValue() with SQLITE3_FLOAT doesn't juggle
We need to ensure that a zval IS_DOUBLE before we access it as such.
In this case we apply common type juggling to do so.
2018-07-26 13:15:19 +02:00
Christoph M. Becker
40bd84d3e3 Fix #76643: Segmentation fault when using output_add_rewrite_var
We have to check whether _SERVER is actually an array before we're
going to use it as such.
2018-07-24 12:20:13 +02:00
Xinchen Hui
38d97557da Fixed bug #68553 (array_column: null values in $index_key become incrementing keys in result) 2018-07-24 11:34:57 +08:00
Christoph M. Becker
99fdf5916e Fix #52974: jewish.c: compile error under Windows with GBK charset
jewish.c includes ISO-8859-8 encoded Hebrew Hebrew month names, which
may cause compile errors, and is generally confusing.  We replace the
literal month names with appropriate escape sequences.
2018-07-22 17:42:10 +02:00
Christoph M. Becker
0f8c1ee76d Fix #73817: Incorrect entries in get_html_translation_table
Due to incorrect string termination and length handling, several HTML
entities missed the trailing semicolon.

We also fix the obviously wrong expectations in two already existing
tests.
2018-07-15 23:06:38 +02:00
Anatol Belski
9026562c79 [ci skip] Update NEWS 2018-07-10 11:50:33 +02:00
cdoco
47fb17b108 Fixed bug #76366 (references in sub-array for filtering breaks the filter) 2018-07-07 12:07:43 +02:00
Anatol Belski
ea24847620 [ci skip] Update NEWS 2018-07-06 17:43:48 +02:00
Sara Golemon
137f22ad36
Fix year 2018-07-06 10:02:20 -04:00
Sara Golemon
268e801cb1
Bump version 2018-07-06 10:02:00 -04:00
Nikita Popov
c97b8bbf82 Fixed bug #75231
The behavior is now consistent with ReflectionMethod.
2018-07-02 18:56:27 +02:00
Nikita Popov
787593b708 Fix test after serialization change
And move it to a more appropriate location.
2018-07-02 17:58:26 +02:00
Nikita Popov
c793885b76 Fixed bug #74670
Validate that "C" serialization payload is followed by "}" prior to
calling the unserialize() handler. This mitigates issues caused by
unserialize() not correctly handling strings that are not NUL
terminated. Making sure that there is a "}" at the end avoids the
problem.
2018-07-02 17:27:43 +02:00