1
0
mirror of https://github.com/php/php-src.git synced 2026-04-26 01:18:19 +02:00
Commit Graph

97 Commits

Author SHA1 Message Date
Sebastian Bergmann 4223aa4d5e MFH: Bump year. 2007-01-01 09:36:18 +00:00
Ilia Alshanetsky 557838efa4 Last set of zend_hash_init() optimizations 2006-10-03 19:51:01 +00:00
Antony Dovgal 99b133d7a7 MFH: fix double free(), add test 2006-09-15 07:27:22 +00:00
Antony Dovgal 9fa594c2dd fix coverity issue #197
"I can't think of a reason to pass a NULL buf" (c) Wez
2006-09-10 13:01:37 +00:00
Ilia Alshanetsky 4427552b60 Fixed bug #38661 (mixed-case URL breaks url-wrappers). 2006-09-03 16:32:27 +00:00
Antony Dovgal 4902fc6c25 MFH: fix #38086 (stream_copy_to_stream() returns 0 when maxlen is bigger than the actual length)
add tests
2006-07-13 12:00:17 +00:00
Hannes Magnusson c4154145df MFH: plug memleak 2006-06-20 18:09:50 +00:00
Rasmus Lerdorf 6bfeea9eb9 MFH: Backported allow_url_include from HEAD. This directive allows
separate control of URL handling in includes/requires allowing sites to
enable allow_url_fopen without enabling remote includes.
2006-06-16 14:09:01 +00:00
Marcus Boerger 3577115118 - MFH Add strict compliant RFC2397 support (no //) 2006-05-14 18:40:12 +00:00
Wez Furlong 8663f1644d fix for #37158 2006-04-22 17:17:40 +00:00
Michael Wallner f7a6327728 - Fix reading stream filters never notified about EOF 2006-04-20 17:43:18 +00:00
foobar 5bd93221a8 bump year and license version 2006-01-01 12:51:34 +00:00
Antony Dovgal 248be6fcfc fix #35781 (stream_filter_append() can cause segfault) 2005-12-23 14:32:11 +00:00
Antony Dovgal aec3b4e73c fix #35740 (memory leak when including a directory) 2005-12-20 09:47:57 +00:00
foobar a3af52c11e MFH: list_entry -> zend_rsrc_list_entry 2005-12-05 23:38:04 +00:00
foobar 23e671a51e - Bumber up year 2005-08-03 14:08:58 +00:00
Dmitry Stogov 8b134356ef Disabled search of recored separator outside of buffer 2005-06-01 15:11:44 +00:00
Antony Dovgal d4db964aed revert by Wez's request 2005-05-23 15:36:58 +00:00
Antony Dovgal 201fbc48e6 fix bug #32810 (fread after tmpfile() reads only 8192 bytes) 2005-05-23 11:51:53 +00:00
Antony Dovgal d5bb03b11a fix bugs #32742 (segmentation fault when the stream with a wrapper is not closed),
#32171 (Userspace stream wrapper crashes PHP)
2005-05-16 08:37:14 +00:00
Ilia Alshanetsky edd4860674 Attempt to eliminate seek() prior to every write. 2005-04-29 19:01:33 +00:00
Antony Dovgal 2a83dbdf1c revert the patch, the problem seems to be somewhere else 2005-04-11 15:19:27 +00:00
Sara Golemon dc8823b565 Fold validation into an inlined function per Andi's suggestion 2005-04-09 19:36:49 +00:00
Antony Dovgal e7a2efe053 do not try to read after EOF 2005-04-06 08:26:06 +00:00
Ilia Alshanetsky d9aea604b3 Fixed bug #30362 (stream_get_line() not reading data correctly). 2005-04-05 03:00:04 +00:00
Sara Golemon 51852db0df BugFix #32563
This could have been done in stream_wrapper_register()
without introducing the slight performance hit on
wrapper registration since anyone registering a wrapper
in an extension should know better.

The important thing is that since locate_wrapper makes
the assumption that all schemes will be /^[a-z0-9+.-]+$/i
Anything which registers them should make the same assumption as well.
2005-04-04 19:34:32 +00:00
Ilia Alshanetsky c7b931d80d Fixed bug #31515 (Improve performance of scandir() by factor of 10 or so). 2005-02-22 00:24:13 +00:00
Ilia Alshanetsky d98a44d483 Fixed bug #29801 (Set limit on the size of mmapable data). 2004-11-15 23:43:12 +00:00
Rob Richards d563495a24 add support for file://localhost/
support file:/// under windows again
2004-11-11 13:08:32 +00:00
Ilia Alshanetsky 5c04e39383 Fixed bug #30362 (stream_get_line() not handling end string correctly). 2004-10-11 18:31:49 +00:00
Sara Golemon 34550382d8 Added stream_filter_remove() to cancel a stream filter.
Register filters as resources when
instantiated by stream_filter_(ap|pre)pend().

Export php_stream_filter_flush() internal function to wind buffered data
out of a particular filter until consumed by a later filter or sent to
stream->readbuffer or stream->ops->write()
2004-09-14 03:48:17 +00:00
Sara Golemon 9cd4320b65 Allocating hash tables should be done via macro, not directly 2004-09-13 21:07:22 +00:00
Sara Golemon ed5dcbff9b A little extra code to allow overriding plainfiles wrapper as well 2004-09-10 21:50:29 +00:00
Sara Golemon 955b43ba12 Add stream_wrapper_unregister()
Disables a wrapper (user-defined or built-in) for the life of the request.

Add stream_wrapper_restore()
Restores the wrapper originally defined at the time the request started
to the protocol name mentioned.
2004-09-10 20:45:35 +00:00
Sara Golemon d179ac771c Handle maxlen when stream can't be mmaped 2004-09-08 18:42:15 +00:00
Antony Dovgal fd6d9cbeac fix bug #29723 (file_get_contents() fails with the file:// wrapper under Win32) 2004-08-31 11:37:02 +00:00
Wez Furlong 971fcd4254 Looks like Sara forgot to change this too. 2004-07-13 16:34:56 +00:00
Wez Furlong ae40d0ef2a Fix file_get_contents() bug... 2004-07-12 20:59:24 +00:00
Wez Furlong cd732f1a3f RIP: greedy ready problems
This allows people to use fread($fp, filesize($filename)) for regular files,
but packet-based non-greedy reads for everything else.
2004-07-10 10:54:09 +00:00
Wez Furlong 8f435013ff Fix for Bug #28964 fread "greedy" behaviour 2004-06-29 21:51:53 +00:00
Sara Golemon a2c24ae90e BugFix#28868 (Part Two): This fixes thread unsafety in the userspace
filters which relates to the fix just applied for userspace wrappers.
2004-06-21 21:08:05 +00:00
Sara Golemon 7fcfa8865e BugFix#28868: Wrapper hash not thread-safe.
Userdefined wrappers were being registered into a global wrapper hash
which can cross threads.  Termination of once instance then has the
potential to leave an active stream in another instance with no wrapper
leading to segfault.
2004-06-21 18:58:55 +00:00
Wez Furlong b369925372 Fix #25939 for good this time.
# How could I miss this??
2004-05-27 13:04:14 +00:00
Sara Golemon 002f7ef393 This leaks when a stream opener proxy opens another stream. 2004-04-01 01:07:54 +00:00
Sara Golemon 72616e6eae BugFix#27619
Filters not applied to pre-buffered stream data.
(esp. http:// streams)
2004-03-31 23:48:59 +00:00
Wez Furlong 70757063a7 add cast for qsort compare function.
Kinda ugly, but helps assert that we are doing the right thing as well as
kill the warning there.
2004-03-07 22:06:36 +00:00
Wez Furlong 0dd2280102 Less magic please 2004-03-07 21:36:55 +00:00
Jon Parise 4db900732d Cast the php_stream_dirent to a 'const char *' for estrndup() to avoid a
compiler warning.
2004-03-01 07:02:23 +00:00
Wez Furlong a44838e8a3 Fix a bug in the persistent socket liveness checks and feof(); they were
using the default socket timeout of 60 seconds before returning the socket
to the calling script.  The reason they were using that value is that the
same code is used for feof(), so the fix is allowing the caller to
indicate the timeout value for liveness checks.

A possible remaining issue now is that 0 second timeout[1] for pfsockopen
is possibly too short; it's impossible to specify a sane value for all
possible uses, so maybe we need a stream context or an .ini option to
control this, or maybe use the timeout value that was passed to
pfsockopen().

# [1] by timeout, I mean the time that PHP will wait for data on a
# persistent socket before deciding if a new connection should be made;
# NOT the timeout while waiting for a new connection to be established.
2004-02-04 22:46:44 +00:00
Sara Golemon 6d10371ec6 'Bug Fix': scandir, being a new function in PHP5 should have always been wrapper aware. 2004-01-28 22:21:54 +00:00