Commit Graph

643 Commits

Author SHA1 Message Date
Ferenc Kovacs
d2ab6e1d15 Merge branch 'PHP-5.6'
* PHP-5.6:
  removing the NEWS entry as we had to revert this fix for now
  Revert "Merge branch 'PHP-5.5' into PHP-5.6"
  Revert "fix TS build"
  Revert "Merge branch 'PHP-5.4' into PHP-5.5"
  Revert "Bug #67965: Fix blocking behavior in non-blocking crypto streams"
  Revert "Bug #41631: Fix regression from first attempt (6569db8)"
2014-10-15 19:41:27 +02:00
Ferenc Kovacs
7b8222aa44 Revert "Merge branch 'PHP-5.4' into PHP-5.5"
This reverts commit 30a73658c6, reversing
changes made to 7fac56e072.
2014-10-15 19:33:31 +02:00
Anatol Belski
b428dc761d Merge branch 'PHP-5.6'
* PHP-5.6:
  increase the polling period to not to break existing behaviours
2014-09-29 17:29:00 +02:00
Anatol Belski
231a311ecb Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  increase the polling period to not to break existing behaviours
2014-09-29 17:28:27 +02:00
Anatol Belski
46aa2c396b increase the polling period to not to break existing behaviours 2014-09-29 17:27:24 +02:00
Anatol Belski
78e23758b7 Merge branch 'PHP-5.6'
* PHP-5.6:
  updated NEWS
  Fixed bug #51800 proc_open on Windows hangs forever

Conflicts:
	main/streams/plain_wrapper.c
2014-09-29 16:30:40 +02:00
Anatol Belski
87a37f4090 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fixed bug #51800 proc_open on Windows hangs forever
2014-09-29 16:27:33 +02:00
Anatol Belski
0c982798e0 Fixed bug #51800 proc_open on Windows hangs forever
This loop can block for some minutes, theoretically. Practially
however, this is a 99% non issue for a normal use case. This is
required because read() is synchronous. The PHP streams API wants
to fill its internal buffers, therefore it might try to read some
more data than user has demanded. Also, for a case where we want
to read X bytes, but neither enough data nor EOF arrives, read()
will block until it could fill the buffer. If a counterpart station
runs slowly or delivers not all the data at once, read() would
still be waiting. If we quit too early, we possibly could loose
some data from the pipe. Thus it has to emulate the read()
behaviour, but obviously not completely, just to some grade.

Reading big data amount is for sure an issue on any platforms, it
depends on the pipe buffer size, which is controlled by the system.
On Windows, the buffer size seems to be way too small, which causes
buffer congestion and a dead lock. It is essential to read the pipe
descriptors simultaneously and possibly in the same order as the
opposite writes them.

Thus, this will work with smaller buffer data sizes passed through
pipes. As MSDN states, anonymous pipes don't support asynchronous
operations. Neither anonymous pipes do support select() as they are
not SOCKETs but file descriptors. Consequently - bigger data sizes
will need a better solution based on threads. However it is much
more expencive. Maybe a better solution could be exporting a part
of the internal doing as a userspace function which could perform
some kind of lookahead operation on the pipe descriptor.

This is just the first stone, depending on the user feedback we
might go for further improvements in this area.
2014-09-29 16:24:34 +02:00
Johannes Schlüter
d0cb715373 s/PHP 5/PHP 7/ 2014-09-19 18:33:14 +02:00
Anatol Belski
6a92d32105 fix type 2014-09-14 14:43:39 +02:00
Anatol Belski
bea0face48 reduce the struct size by 8 bytes on 64 bit 2014-09-12 23:10:56 +02:00
Anatol Belski
9adf0c8e07 better alignment, reduced the struct by 8 byte on 64 bit 2014-09-12 21:35:18 +02:00
Anatol Belski
10f856386d fix type 2014-09-12 21:35:17 +02:00
Anatol Belski
3234480827 first show to make 's' work with size_t 2014-08-27 20:49:31 +02:00
Chris Wright
0a1df74895 Merge branch 'PHP-5.6'
* PHP-5.6:
  Fix stream_select() issue with OpenSSL buffer
2014-08-27 16:35:28 +01:00
Chris Wright
db03216e62 Merge branch 'PHP-5.5' into PHP-5.6
* PHP-5.5:
  Fix stream_select() issue with OpenSSL buffer
2014-08-27 16:06:28 +01:00
Chris Wright
30a73658c6 Merge branch 'PHP-5.4' into PHP-5.5
* PHP-5.4:
  Fix stream_select() issue with OpenSSL buffer

Conflicts:
	ext/openssl/xp_ssl.c
2014-08-27 16:01:18 +01:00
Chris Wright
32be79dcfa Fix stream_select() issue with OpenSSL buffer
Ensure data from OpenSSL internal buffer has been
transfered to PHP stream buffer before a select()
emulation operation is performed

Addresses bug #65137
https://bugs.php.net/bug.php?id=65137

Conflicts:
	ext/openssl/xp_ssl.c
2014-08-27 13:25:50 +01:00
Anatol Belski
b63ab83256 several signature and data type fixes 2014-08-26 13:20:21 +02:00
Anatol Belski
202e8db1dc fixed several long vs zend_long casts 2014-08-26 11:26:53 +02:00
Anatol Belski
af59e92b24 master renames phase 7 2014-08-25 21:51:49 +02:00
Anatol Belski
455741fce3 master renames phase 4 2014-08-25 20:57:25 +02:00
Anatol Belski
4d997f63d9 master renames phase 3 2014-08-25 20:22:49 +02:00
Anatol Belski
c3e3c98ec6 master renames phase 1 2014-08-25 19:24:55 +02:00
Anatol Belski
8ee2a4a9b5 first shot on merging the core fro the int64 branch 2014-08-16 11:16:11 +02:00
Dmitry Stogov
b59cc8de23 cleanup (we don't have to duplicate elements of stream_filters_hash) 2014-08-13 17:00:13 +04:00
Dmitry Stogov
5a06ac88da cleanup (use zend_string* instead of char*) 2014-08-13 14:51:48 +04:00
Dmitry Stogov
4c716e8b51 Merge branch 'master' into test
* master: (39 commits)
  Add __debugInfo() to UPGRADING.
  fix TS build
  Update NEWS
  Update NEWS
  Update NEWS
  Small tidy ups and raise visibility of GitHub PR process
  Bug #41631: Observe socket read timeouts in SSL streams
  wrap int8_t and int16_t with #ifdef to avoid possible clashes
  - Updated to version 2014.6 (2014f)
  Removed Countable::count() change info from UPGRADE.INTERNALS too
  NEWS and UPGRADING for intdiv()
  Revert "Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option"
  Fixed skip case for intdiv 64-bit test
  Use callback structure
  Add EXPECTF
  Fix handling of multi-result sets with PS...used to clean not only the result set but the whole PS.
  5.5.17 now
  5.4.33-dev now
  Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option
  Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option
  ...

Conflicts:
	ext/fileinfo/libmagic/softmagic.c
	main/streams/xp_socket.c
2014-08-11 11:38:41 +04:00
Dmitry Stogov
4a3e501fb3 cleanup 2014-08-08 13:47:34 +04:00
Dmitry Stogov
417ed16d11 Make stream->context indirect trough zend_resource (stream->ctx->ptr).
Fixed ext/standard/tests/streams/bug61115.phpt
2014-08-07 15:55:37 +04:00
Ferenc Kovacs
791c87ae48 Revert "Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option"
This reverts commit a51bf0cadf.
2014-08-06 20:33:48 +02:00
Daniel Lowrey
a51bf0cadf Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option 2014-08-05 23:13:04 -04:00
Daniel Lowrey
f6b530bd54 Merge branch 'PHP-5.6' 2014-08-05 22:58:45 -04:00
Daniel Lowrey
60552a8871 Add SO_REUSEPORT + SO_BROADCAST support via socket stream context option 2014-08-05 22:43:12 -04:00
Dmitry Stogov
e3b610c245 typo 2014-08-05 20:55:15 +04:00
Dmitry Stogov
da2097b349 Fixed argument numbering 2014-08-05 18:17:05 +04:00
Dmitry Stogov
b5590a2f87 Fixed incorrect arguments handling 2014-08-04 21:31:13 +04:00
Dmitry Stogov
449f3e6452 Fixed resource leak 2014-07-31 10:53:31 +04:00
Dmitry Stogov
bce6a36c8a Merge branch 'master' into test
* master: (48 commits)
  change locale - looks like not everybody has sl_SI
  Fix bug #66921 - Wrong argument type hint for function intltz_from_date_time_zone
  fix format
  Fix bug #67052 (NumberFormatter::parse() resets LC_NUMERIC setting)
  Make sure the generator script also creates a newline at the end of file
  Add newline at end of file to prevent compilation warning
  Fix handling of session user module custom handlers.
  Reference bug report instead of github issue in NEWS file
  add more exts for Travis
  Update NEWS
  Fix phpdbg.1 man page installation when build != src directory
  BFN for bug #67551 (php://input temp file will be located in sys_temp_dir instead of upload_tmp_dir)
  reorder
  restore API compatibility
  finish
  refactor php_stream_temp_create{,_ex} and use it for the php://input stream
  refactor _php_stream_fopen_{temporary_,tmp}file()
  fix length overflow of HTTP_RAW_POST_DATA
  Update NEWS
  Fixed bug #67215 (php-cgi work with opcache, may be segmentation fault happen)
  ...

Conflicts:
	ext/opcache/zend_accelerator_util_funcs.c
	ext/session/mod_user.c
	ext/spl/spl_array.c
	ext/spl/spl_dllist.c
	ext/standard/file.c
	ext/standard/streamsfuncs.c
	ext/standard/string.c
	main/streams/memory.c
2014-07-07 19:21:23 +04:00
Michael Wallner
f9fda21667 Merge branch 'PHP-5.6'
* PHP-5.6:
  BFN for bug #67551 (php://input temp file will be located in sys_temp_dir instead of upload_tmp_dir)
  reorder
  restore API compatibility
  finish
  refactor php_stream_temp_create{,_ex} and use it for the php://input stream
  refactor _php_stream_fopen_{temporary_,tmp}file()
  fix length overflow of HTTP_RAW_POST_DATA

Conflicts:
	main/php_content_types.c
2014-07-03 20:43:12 +02:00
Michael Wallner
deee0011e1 restore API compatibility 2014-07-03 20:40:41 +02:00
Michael Wallner
438b6c5258 finish 2014-07-03 20:40:40 +02:00
Michael Wallner
40bcd909d8 refactor php_stream_temp_create{,_ex} and use it for the php://input stream 2014-07-03 20:40:40 +02:00
Michael Wallner
11e401ab59 refactor _php_stream_fopen_{temporary_,tmp}file() 2014-07-03 20:40:40 +02:00
Dmitry Stogov
2777662694 Hide warning message after fatal errors 2014-06-20 13:31:43 +04:00
Dmitry Stogov
5152422194 Check if socket is still alive 2014-06-20 13:31:23 +04:00
Xinchen Hui
922285ec55 Don't use cast (compiler friendly) 2014-05-26 11:05:04 +08:00
Xinchen Hui
59d74db108 Fixed segafult while stream is referenced by persistent resource (like dba) 2014-05-21 13:11:56 +08:00
Xinchen Hui
98f801ccbc Fixed resources apply_dtor 2014-05-19 14:53:02 +08:00
Xinchen Hui
d86fa38cc5 Fixed uninitialized used 2014-05-18 21:04:43 +08:00