Commit Graph

5156 Commits

Author SHA1 Message Date
Nikita Popov
a9969ec1bd Merge branch 'PHP-7.4' 2019-07-22 12:41:20 +02:00
Nikita Popov
72b9105d30 Merge branch 'PHP-7.3' into PHP-7.4 2019-07-22 12:41:15 +02:00
Nikita Popov
b59a9381b9 Remove test for bug #77185
Seems to be very unreliable in CI.
2019-07-22 12:40:26 +02:00
Nikita Popov
8092604ec2 Merge branch 'PHP-7.4' 2019-07-22 11:19:32 +02:00
Nikita Popov
b2915fc332 Merge branch 'PHP-7.3' into PHP-7.4 2019-07-22 11:19:24 +02:00
Nikita Popov
5e4dbce586 Reduce number of workers in test
4 seems to be enough to reliably reproduce the issue. Let's see
if this works better in CI.
2019-07-22 11:18:38 +02:00
Nikita Popov
a16ca769af Merge branch 'PHP-7.4' 2019-07-22 10:34:58 +02:00
Nikita Popov
97b80bd83b Merge branch 'PHP-7.3' into PHP-7.4 2019-07-22 10:34:32 +02:00
Maksim Nikulin
bdf24f8d6d Prevent use after free in fpm_event_epoll_wait
epoll event backend does not guarantee that child input/output events
are reported before SIGCHILD due to finished worker. While a bunch of
events received by epoll is being processed, child-related structures
may be removed before dispatching of an I/O event for the same child.
The result may be attempt to access to memory region allocated for
another purpose, segfault of the master process, and unavailable web
sites.

Postpone processing of SIGCHILD events till other events in the same
bunch are processed.

Fix Bug #62418 php-fpm master process crashes
Fix Bug #65398 Race condition between SIGCHLD and child stdout/stderr event leads to segfault
Fix Bug #75112 php-fpm crashing, hard to reproduce
Fix Bug #77114 php-fpm master segfaults in fpm_event_epoll_wait/fpm_event_fire
Fix Bug #77185 Use-after-free in FPM master event handling
2019-07-22 10:32:58 +02:00
George Wang
e4f6744552 Merge branch 'PHP-7.4' 2019-07-21 00:02:03 -04:00
George Wang
30de357fa1 Merge branch 'PHP-7.3' into PHP-7.4 2019-07-21 00:01:39 -04:00
George Wang
82f35ab089 Merge branch 'PHP-7.2' into PHP-7.3 2019-07-21 00:01:06 -04:00
George Wang
eb7e45f662 Checked in LiteSpeed SAPI 7.5, addressed two main problems in "clean shutdown" introduced in 7.4.3,
1. falls in an infinite loop because PHP engine's inconsistent state, now override the ITIMER_PROF to 0.1 second, clean shutdown must finish before that.
2. generate too much error log, we completely disable "error_reporting" before calling php_request_shutdown().
2019-07-20 23:59:43 -04:00
Nikita Popov
eb766751dc Merge branch 'PHP-7.4' 2019-07-19 10:06:30 +02:00
rjhdby
d574df63dc Deprecate alternative array access syntax
RFC: https://wiki.php.net/rfc/deprecate_curly_braces_array_access
2019-07-19 10:06:10 +02:00
Peter Kokot
f33d12096d Merge branch 'PHP-7.4'
* PHP-7.4:
  Remove duplicate socklen_t check
2019-07-18 12:11:45 +02:00
Peter Kokot
bbdbc2658c Remove duplicate socklen_t check
- Use Autoconf's default AC_CHECK_TYPES

Closes GH-4418
2019-07-18 12:11:19 +02:00
Nikita Popov
b32e9a9227 Merge branch 'PHP-7.4' 2019-07-17 10:41:34 +02:00
Nikita Popov
a986e70991 Avoid double buffering in Zend streams
Disable buffering in PHP streams, to avoid storing and copying the
file contents twice.

This will call stream_set_option() on custom stream wrapper as
well, so the method needs to be implemented to avoid a warning.
2019-07-17 10:40:04 +02:00
Nikita Popov
c4a6998c62 Merge branch 'PHP-7.4' 2019-07-16 17:45:03 +02:00
Nikita Popov
b317f0eb59 Remove ZEND_HANDLE_MAPPED
The buf/len members are now simply used in addition to the main
stream, without changing the handle kind.
2019-07-16 17:44:32 +02:00
Nikita Popov
e0eca26285 Drop free_filename field from zend_file_handle
free_filename was always zero.
2019-07-16 17:07:26 +02:00
Nikita Popov
3faa903d47 Merge branch 'PHP-7.4' 2019-07-16 16:44:46 +02:00
Nikita Popov
49bac9b77b Introduce zend_stream_init_filename()
Avoid more ad-hoc initialization of zend_file_handle structures.
2019-07-16 16:44:37 +02:00
Nikita Popov
46faf8f018 Introduce zend_stream_init_fp() API
Reduce the amount of code that mucks around with zend_file_handle
initialization.
2019-07-16 16:44:37 +02:00
Nikita Popov
c562d71d12 Merge branch 'PHP-7.4' 2019-07-16 11:11:08 +02:00
Nikita Popov
ebfa05677b Merge branch 'PHP-7.3' into PHP-7.4 2019-07-16 11:11:00 +02:00
Nikita Popov
eea9d61763 Merge branch 'PHP-7.2' into PHP-7.3 2019-07-16 11:10:51 +02:00
Nikita Popov
8a19fe29de Fixed bug #78297 2019-07-16 11:09:17 +02:00
Nikita Popov
9207aef60c Merge branch 'PHP-7.4' 2019-07-15 16:26:25 +02:00
Nikita Popov
c5f1b384b5 Move shebang handling into the lexer
Instead of handling shebang lines by adjusting the file pointer in
individual SAPIs, move the handling into the lexer, where this is
both a lot simpler and more robust. Whether the shebang should be
skipped is controlled by CG(skip_shebang) -- we might want to do
that in more cases.

This fixed bugs #60677 and #78066.
2019-07-15 16:25:49 +02:00
Nikita Popov
74bf7bfb88 Merge branch 'PHP-7.4' 2019-07-11 15:49:02 +02:00
Nikita Popov
17f7fb7605 Switch to using shell-less proc_open() in various server tests 2019-07-11 15:48:10 +02:00
Nikita Popov
bbd12b3d30 Merge branch 'PHP-7.4' 2019-07-10 11:11:30 +02:00
Nikita Popov
dfe5fd2a37 Avoid invalid array access in fcgi.inc 2019-07-10 11:09:34 +02:00
Nikita Popov
5f0c8f5e30 Merge branch 'PHP-7.4' 2019-07-09 16:20:12 +02:00
David Carlier
aa0e29a668 CGI: Fix memory leak on error paths 2019-07-09 16:19:41 +02:00
Peter Kokot
35709b56e4 Merge branch 'PHP-7.4'
* PHP-7.4:
  Remove some more Apache 1 left overs
2019-07-07 12:10:59 +02:00
Peter Kokot
49cc2a63b3 Remove some more Apache 1 left overs
- warning in configure.ac is relevant for the sapi/apache
- errors output redirected to /dev/null when checking Apache version
2019-07-07 12:09:19 +02:00
George Wang
dfce767a62 Merge branch 'PHP-7.4' 2019-07-04 12:15:25 -04:00
George Wang
6a403504e7 Merge branch 'PHP-7.3' into PHP-7.4 2019-07-04 12:14:48 -04:00
George Wang
3ec8776940 Merge branch 'PHP-7.2' into PHP-7.3 2019-07-04 12:04:08 -04:00
George Wang
32af676bd9 Updated to LiteSpeed SAPI V7.4.3
Increased response header count limit from 100 to 1000.
Added crash handler to cleanly shutdown PHP request.
Added CloudLinux mod_lsapi mode
Fixed bug #76058
2019-07-04 12:03:21 -04:00
Joe Watkins
f1f63c0cec
Merge branch 'PHP-7.4'
* PHP-7.4:
  improvements to cli server
2019-07-03 16:31:55 +02:00
Joe Watkins
30019f47a5
improvements to cli server 2019-07-03 16:30:51 +02:00
Nikita Popov
fe2aca83ce Merge branch 'PHP-7.4' 2019-07-01 16:14:58 +02:00
Nikita Popov
af3e2d3186 Initialize last_line in phpdbg globals 2019-07-01 16:14:45 +02:00
Joe Watkins
22fb96ab85
Merge branch 'PHP-7.4'
* PHP-7.4:
  implement support for workers in cli-server on platforms supporting fork
2019-06-29 05:28:12 +02:00
Joe Watkins
82effb3fc7
implement support for workers in cli-server on platforms supporting fork 2019-06-29 05:27:35 +02:00
Nikita Popov
8f0729cb65 Merge branch 'PHP-7.4' 2019-06-28 17:47:45 +02:00