Commit Graph

13700 Commits

Author SHA1 Message Date
Nikita Popov
12e88781e1 Merge branch 'PHP-7.2' into PHP-7.3 2018-11-27 19:44:45 +01:00
Nikita Popov
b565c85b9e Improve fix for #76046
Also locate the JMP at the start of the foreach.

Patch suggested by Derick.
2018-11-27 19:43:25 +01:00
Nikita Popov
d78211aec0 Merge branch 'PHP-7.2' into PHP-7.3 2018-11-27 16:39:21 +01:00
Nikita Popov
d6595f276f Fixed bug #76046
Place FE_FREE on start line of foreach, instead of whatever random
line number might be in CG(zend_lineno) at the time.
2018-11-27 16:37:55 +01:00
Nikita Popov
b6d5d92661 Merge branch 'PHP-7.2' into PHP-7.3 2018-11-20 21:30:53 +01:00
Nikita Popov
bbbaf1ca85 Merge branch 'PHP-7.1' into PHP-7.2 2018-11-20 21:30:38 +01:00
Valentin V. Bartenev
11ddf7669a Fix bug #71041 dynamic embed SAPI load error
If the library is built with ZEND_SIGNALS defined, it's unusable with an
external SAPI module because the zend_signal_startup() call is mandatory
in this case.

This bug is similar to #74149, but related to dynamic loading of PHP library.
2018-11-20 21:30:02 +01:00
Nikita Popov
dee5a450d9 Fixed bug #77165
Also add some helper macros for PROTECT/UNPROTECT that check for
IMMUTABLE. These checks are needed for nearly any use of
PROTECT/UNPROTECT.
2018-11-15 17:16:39 +01:00
Jan Rękorajski
f76be1a0d6 Fix compilation on x32
Signed-off-by: Elan Ruusamäe <glen@pld-linux.org>
2018-11-13 12:31:00 +01:00
Christoph M. Becker
7625f972db Fix #76825: Undefined symbols ___cpuid_count
Apparently, the presence of `cpuid.h` is not necessarily sufficient to
guarantee the availability of `__cpuid_count()`.  We therefore test for
the latter explicitly.
2018-11-05 18:24:39 +01:00
Remi Collet
d53ecd040b Fix: #77110 undefined symbol zend_string_equal_val in C++ build 2018-11-05 17:05:49 +01:00
Zeev Suraski
9afce019e0 Future-proof email addresses 2018-11-01 18:35:32 +02:00
Peter Kokot
6b8605d31f Fix failing Zend/tests due to newlines 2018-10-15 05:04:29 +02:00
Peter Kokot
b746e69887 Sync leading and final newlines in *.phpt sections
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines in all
*.phpt sections.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-15 04:32:30 +02:00
Peter Kokot
f1d7e3ca0b Sync leading and final newlines in *.phpt sections
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines in all
*.phpt sections.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-15 04:31:31 +02:00
Peter Kokot
113213f027 Sync leading and final newlines in *.phpt sections
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines in all
*.phpt sections.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-15 04:29:24 +02:00
Peter Kokot
782352c54a Trim trailing whitespace in *.phpt 2018-10-14 19:45:12 +02:00
Peter Kokot
17ccbeec32 Trim trailing whitespace in *.phpt 2018-10-14 19:44:14 +02:00
Peter Kokot
7af945e271 Trim trailing whitespace in *.phpt 2018-10-14 19:43:12 +02:00
Peter Kokot
1c850bfcca Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-14 12:55:24 +02:00
Peter Kokot
60a69daec6 Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-14 12:54:08 +02:00
Peter Kokot
03f3b8479b Sync leading and final newlines in source code files
This patch adds missing newlines, trims multiple redundant final
newlines into a single one, and trims redundant leading newlines.

According to POSIX, a line is a sequence of zero or more non-' <newline>'
characters plus a terminating '<newline>' character. [1] Files should
normally have at least one final newline character.

C89 [2] and later standards [3] mention a final newline:
"A source file that is not empty shall end in a new-line character,
which shall not be immediately preceded by a backslash character."

Although it is not mandatory for all files to have a final newline
fixed, a more consistent and homogeneous approach brings less of commit
differences issues and a better development experience in certain text
editors and IDEs.

[1] http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/V1_chap03.html#tag_03_206
[2] https://port70.net/~nsz/c/c89/c89-draft.html#2.1.1.2
[3] https://port70.net/~nsz/c/c99/n1256.html#5.1.1.2
2018-10-14 12:51:01 +02:00
Peter Kokot
3362620b5f Trim trailing whitespace in source code files 2018-10-13 14:16:33 +02:00
Peter Kokot
902d39a3a7 Trim trailing whitespace in source code files 2018-10-13 14:14:50 +02:00
Peter Kokot
7f6387b59a Trim trailing whitespace in source code files 2018-10-13 14:12:55 +02:00
Peter Kokot
85290bbfcc Convert CRLF line endings to LF
This patch simplifies line endings tracked in the Git repository and
syncs them to all include the LF style instead of the CRLF files.

Newline characters:
- LF (\n) (*nix and Mac)
- CRLF (\r\n) (Windows)
- CR (\r) (old Mac, obsolete)

To see which line endings are in the index and in the working copy the
following command can be used:
`git ls-files --eol`

Git additionally provides `.gitattributes` file to specify if some files
need to have specific line endings on all platforms (either CRLF or LF).

Changed files shouldn't cause issues on modern Windows platforms because
also Git can do output conversion is core.autocrlf=true is set on
Windows and use CRLF newlines in all files in the working tree.

Unless CRLF files are tracked specifically, Git by default tracks all
files in the index using LF newlines.
2018-10-13 11:23:20 +02:00
Peter Kokot
3f72c77ce4 Convert CRLF line endings to LF
This patch simplifies line endings tracked in the Git repository and
syncs them to all include the LF style instead of the CRLF files.

Newline characters:
- LF (\n) (*nix and Mac)
- CRLF (\r\n) (Windows)
- CR (\r) (old Mac, obsolete)

To see which line endings are in the index and in the working copy the
following command can be used:
`git ls-files --eol`

Git additionally provides `.gitattributes` file to specify if some files
need to have specific line endings on all platforms (either CRLF or LF).

Changed files shouldn't cause issues on modern Windows platforms because
also Git can do output conversion is core.autocrlf=true is set on
Windows and use CRLF newlines in all files in the working tree.

Unless CRLF files are tracked specifically, Git by default tracks all
files in the index using LF newlines.
2018-10-13 11:21:27 +02:00
Nikita Popov
01948f20b8 Fixed bug #76991
Back up exceptions while the scan-ahead loop, to avoid an early
bail out.
2018-10-10 15:00:18 +02:00
Pierrick Charron
44d2c8c6dd Merge branch 'PHP-7.2' into PHP-7.3 2018-10-09 01:26:55 -04:00
Pierrick Charron
efa5674a9b Merge branch 'PHP-7.1' into PHP-7.2 2018-10-09 01:20:01 -04:00
Pierrick Charron
f42d7bddc0 Fixed bug #76965 INI_SCANNER_RAW doesn't strip trailing whitespace 2018-10-09 00:00:21 -04:00
Michael Moravec
0a6ddc7722 Fix bug #76979: define() error message does not mention resources as valid values 2018-10-06 11:21:51 +02:00
Nikita Popov
b8392803f9 Merge branch 'PHP-7.2' into PHP-7.3 2018-10-02 17:48:56 +02:00
Nikita Popov
d2477b284b Fixed bug #76936 2018-10-02 17:47:07 +02:00
Nikita Popov
8b8b625d08 Fixed bug #72635
This seems to be a simple oversight, where we did not enable
exceptions. Other constexpr conditions already throw, so there is
no particular reason to stick to a fatal error here.
2018-09-29 14:21:08 +02:00
Nikita Popov
7189e0b70f Merge branch 'PHP-7.2' into PHP-7.3 2018-09-28 19:17:53 +02:00
Nikita Popov
8e7dfc6ddf Merge branch 'PHP-7.1' into PHP-7.2 2018-09-28 19:17:29 +02:00
Nikita Popov
83e2b9e220 Fixed bug #76946 2018-09-28 19:15:19 +02:00
Nikita Popov
8ebe1b8de1 Merge branch 'PHP-7.2' into PHP-7.3 2018-09-28 13:41:29 +02:00
Nikita Popov
99eb4b2ea4 Merge branch 'PHP-7.1' into PHP-7.2 2018-09-28 13:41:06 +02:00
Nikita Popov
fa84b8ebb4 Fix test for release builds 2018-09-28 13:40:58 +02:00
Nikita Popov
25522baec4 Merge branch 'PHP-7.2' into PHP-7.3 2018-09-28 12:58:59 +02:00
Nikita Popov
1c35357b31 Merge branch 'PHP-7.1' into PHP-7.2 2018-09-28 12:57:55 +02:00
Nikita Popov
45cdcb2d0b Fixed bug #76846 2018-09-28 12:56:47 +02:00
Nikita Popov
040ca85eac Merge branch 'PHP-7.2' into PHP-7.3 2018-09-19 09:39:31 +02:00
Nikita Popov
cc1fb02760 Merge branch 'PHP-7.1' into PHP-7.2 2018-09-19 09:39:13 +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
Dmitry Stogov
b25bc917ec Allow switching back to Zend MM heap. 2018-09-17 20:20:13 +03:00
Dmitry Stogov
17c7b71057 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fixed bug #76800 (foreach inconsistent if array modified during loop)
2018-09-14 10:32:31 +03:00
Dmitry Stogov
3bc4a63fc2 Fixed bug #76800 (foreach inconsistent if array modified during loop) 2018-09-14 10:28:31 +03:00