Commit Graph

4882 Commits

Author SHA1 Message Date
Zeev Suraski
38c337f22e Remove year range from copyright notice 2019-01-30 11:00:23 +02:00
George Wang
276d3a7d15 Merge branch 'PHP-7.3' 2019-01-20 15:11:58 -05:00
George Wang
6a0a600176 Merge branch 'PHP-7.2' into PHP-7.3 2019-01-20 15:11:37 -05:00
George Wang
66d72377d0 Checkin LiteSpeed SAPI 7.2. 2019-01-20 15:10:19 -05:00
Jakub Zelenka
4f7b6fc8ec Merge branch 'PHP-7.3' 2019-01-17 18:38:59 +00:00
Jakub Zelenka
766b4fd515 Fix bug #77430 (php-fpm crashes with Main process exited) 2019-01-17 18:37:09 +00:00
Nikita Popov
d0fd2be642 Revert removal of private __clone() methods
I thought these were redundant, because we already NULL out the
clone_obj object handler. However, it turns out that reflection is
using private __clone() to determine clonability (isCloneable) for
the case where we only have a class, rather than an object.

As such, removing these methods would be a BC break.

This reverts commit e7131a4e9f.
This reverts commit 55bd88ce0d.
2019-01-14 09:19:30 +01:00
Dmitry Stogov
cec091176c Replace zend_hash_apply... with ZEND_HASH_FOREACH... 2018-12-19 02:49:56 +03:00
Craig Andrews
40c4d7f182 Implement FR #72510: systemd service should be hardened 2018-12-12 17:12:02 +01:00
Nikita Popov
e7131a4e9f Remove redundant Exception::__clone() method
Exceptions already prohibit cloning by setting clone_obj to NULL
(which is integrated with reflection). No need to additionally
define a dummy __clone() method.
2018-11-26 13:57:17 +01:00
Christoph M. Becker
1acac320c5 Clean up server-tests.php remains
sapi/tests/ has been introduced as a generic means to test different
SAPIs[1].  run-tests2.php has later be renamed to server-tests.php and
recently been dropped[2].  However, the sapi/tests/test00?.php test
cases remained, even though they make no sense for run-tests.php,
since they use an unsupported format for the `--ENV--` section and the
completely unsupported `--HEADERS--` section, respectively.  While
these tests ran successfully under run-tests.php, that was only by
accident, and they did not really test something useful.  Therefore, we
remove these tests altogether.

sapi/tests/bug69487.phpt is actually a CGI test (CGI is enforced due to
the `--POST--` section), so we move it to sapi/cgi/tests, which leaves
sapi/tests/ empty.  Thus, we also remove the sapi/ directory from
run-tests.php.

Finally, we remove the `--HEADERS--` and `--REQUEST--` sections from
the list of allowed run-tests.php sections.

[1] <http://git.php.net/?p=php-src.git;a=commit;h=b671380b6b5b6e1f4f235e810afa4199e989d2ba>
[2] <http://git.php.net/?p=php-src.git;a=commit;h=4f36acb9e65935aa657f1f22e2320a401bdbdad3>
2018-11-23 16:24:51 +01:00
Anatol Belski
b0cf54c5b8 Merge branch 'PHP-7.3'
* PHP-7.3:
  Fixed bug #77111 php-win.exe corrupts unicode symbols from cli parameters
2018-11-16 23:23:00 +01:00
Anatol Belski
00c08a2e4a Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fixed bug #77111 php-win.exe corrupts unicode symbols from cli parameters
2018-11-16 23:22:19 +01:00
Anatol Belski
a7e9790969 Fixed bug #77111 php-win.exe corrupts unicode symbols from cli parameters
The binary can be of course used on console, for whatever reasons, so
UNICODE API should be used in that case. That might however not work as
expected, if the binary is used for a service.
2018-11-16 23:19:33 +01:00
Peter Kokot
f0251a8b16 Remove lexer files generated by RE2C
This patch removes generated lexer files by re2c during the build
process so they are not tracked by Git yet can be still shipped when
PHP is released. The genfiles script additionally provides generation
of these lexer files when creating a release of the PHP source code.

The genfiles script refactorings:
- added file header
- echoing steps instead of comments
- cleaning only lines starting with `#line`
- eval removed in favor of direct executed commands
- the debug mode `set -x` removed
- script can be called from any path
- improved comments
2018-11-11 02:55:46 +01:00
Zeev Suraski
9afce019e0 Future-proof email addresses 2018-11-01 18:35:32 +02:00
Zeev Suraski
67e0138c0d Future-proof email addresses... 2018-11-01 18:30:28 +02:00
Rasmus Lerdorf
b91690c892 Merge branch 'PHP-7.3'
* PHP-7.3:
  Fix stray newline that caused this test to fail
2018-10-31 11:41:42 -07:00
Rasmus Lerdorf
99a9e85c65 Fix stray newline that caused this test to fail 2018-10-31 11:41:17 -07:00
Dmitry Stogov
ea2e67876a Stop Apache if PHP wasn't started successful. 2018-10-29 21:39:26 +03:00
Dmitry Stogov
10abc1f010 Don't wrap php_module_shutdown() with zend_try. executor_globals are released in ZTS build, and this leads to crash. 2018-10-25 23:41:26 +03:00
Dmitry Stogov
a404383118 Fixed build in directory different from source 2018-10-24 12:45:04 +03:00
Peter Kokot
c0446d55a2 Remove phpdbg parser files generated by bison
The parser files for phpdbg are generated by bison from the *.y file.
Parser files in Zend already follows such approach of these files being
ignored from tracking in the Git repository and they are shipped via
the release packages. This way the end user still don't need to have
bison dependency installed to install PHP.

The genfiles script was refactored to generate the phpdbg parser and lexer
files.

Empty comment in phpdbg parser y template file has been changed to the
YACC compliant /* empty */ instead of custom one.
2018-10-23 19:04:13 +02:00
Nikita Popov
1362d8e103 Fix conflicts in phpdbg parser 2018-10-23 16:22:16 +02:00
Jakub Zelenka
751dfc7514 Merge branch 'PHP-7.3' 2018-10-21 19:40:53 +01:00
Jakub Zelenka
c8febbe039 Fix arginfo and clean up fpm_get_status 2018-10-21 19:39:47 +01:00
Peter Kokot
d679f02295 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:33:09 +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
d7a3edd45d Trim trailing whitespace in *.phpt 2018-10-14 19:46:15 +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
Gabriel Caruso
9c144e0d82
Trim trailing whitespace in tests 2018-10-14 12:07:20 -03:00
Peter Kokot
1ad08256f3 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:56:38 +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
37c329d715 Trim trailing whitespace in source code files 2018-10-13 14:17:28 +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
Nikita Popov
7ec8087f80 Introduce get_properties_for() handler
This handler allows getting the object properties for a particular
purpose, such as array casting, serialization, etc.
2018-10-10 10:39:10 +02:00
Christoph M. Becker
c266a19094 Merge branch 'PHP-7.3'
* PHP-7.3:
  Fix #76954: apache_response_headers removes last character from header name
2018-10-08 12:33:32 +02:00
Christoph M. Becker
6178786233 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fix #76954: apache_response_headers removes last character from header name
2018-10-08 12:32:52 +02:00
Christoph M. Becker
879c937a27 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Fix #76954: apache_response_headers removes last character from header name
2018-10-08 12:30:45 +02:00
stodorovic
47b89bc531 Fix #76954: apache_response_headers removes last character from header name 2018-10-08 12:29:31 +02:00
Anatol Belski
1c11fc7f13 Merge branch 'PHP-7.3'
* PHP-7.3:
  Avoid code duplication and don't miss env restore
2018-10-03 14:36:09 +02:00
Anatol Belski
8400f73f8d Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Avoid code duplication and don't miss env restore
2018-10-03 14:35:38 +02:00
Anatol Belski
b8cfa09657 Merge branch 'PHP-7.1' into PHP-7.2
* PHP-7.1:
  Avoid code duplication and don't miss env restore
2018-10-03 14:34:08 +02:00
Anatol Belski
044eb39e63 Avoid code duplication and don't miss env restore 2018-10-03 14:32:52 +02:00
Anatol Belski
3ad2ab6e7d Merge branch 'PHP-7.3'
* PHP-7.3:
  Fixed bug #76948 Failed shutdown/reboot or end session in Windows
2018-10-03 12:15:54 +02:00
Anatol Belski
46bc0940e7 Merge branch 'PHP-7.2' into PHP-7.3
* PHP-7.2:
  Fixed bug #76948 Failed shutdown/reboot or end session in Windows
2018-10-03 12:15:15 +02:00