Commit Graph

144 Commits

Author SHA1 Message Date
Ilia Alshanetsky
87a8b04051 Fix ZTS build. 2002-12-31 00:04:52 +00:00
Ilia Alshanetsky
0acb52fc3b Fixed bug #21228 (broken check for ob_gzhandler).
Fixed a bug that made ob_start return incorrect return value.
2002-12-30 19:39:31 +00:00
Zeev Suraski
1143a7023c Whitespace 2002-10-07 11:21:06 +00:00
Zeev Suraski
df55f35798 Revert the implicit_flush mess.
Do not revert it again under any circumstances!

Yasuo/anybody else - if there are issues with implicit_flush, please inform
me and I will fix them.
2002-10-06 12:02:53 +00:00
Zeev Suraski
de36720e0e Begin the cleanup - remove ob_flush_all() 2002-10-06 09:06:24 +00:00
Marcus Boerger
518e61de97 suggest paranthesis around || and && 2002-10-04 17:11:35 +00:00
Yasuo Ohgaki
39b0eb9b22 Fixed broken code by Derick.
ob_implicit_flush() and ob_flush_all() are stopped working.
var_dump() and hightlisht_string() outputs buffer contents wrongly
with ob_implicit_flush().

Everyone should be happy now.
It was only OG(implicit_flush) interpretation issue after all.
2002-10-03 13:32:01 +00:00
James Moore
df431074de Keep comments and code in sync. 2002-10-03 11:56:10 +00:00
Sebastian Bergmann
b169932d1c Fix warnings. 2002-10-03 11:08:09 +00:00
Derick Rethans
9b517c4b93 - Revert changed to implicit_flush behavior. The new behavior was not
intended in the first place.
2002-10-03 10:35:33 +00:00
Yasuo Ohgaki
6c7202e116 Added comment for php_output_set_status().
Please use this function if you would like to prevent unwanted flush
by implicit_flush=On or ob_implicit_flush().
2002-10-03 08:54:13 +00:00
Yasuo Ohgaki
66a50c5373 Added ob_flush_all() that flushes bufferred contents until it actually
sent/printed.
@ Added ob_flush_all() that flushes all buffers. (Yasuo)
2002-10-03 07:17:14 +00:00
Yasuo Ohgaki
f534dc8f47 Added missing proto and foldings. 2002-10-03 04:17:41 +00:00
Yasuo Ohgaki
22bf29384e Move wrong output buffer usage check to ob_gzhandler init.
Export some output buffer functions.
2002-10-03 03:58:12 +00:00
Yasuo Ohgaki
bec4574f57 Made some functions inline.
Added static for unexported functions.
2002-10-03 02:55:19 +00:00
Yasuo Ohgaki
bd177ce7c1 Added ob_get_clean() and ob_get_flush().
Someone requested this feature before.
@ Added ob_get_clean() and og_get_flush(). (Yasuo)
2002-10-03 01:36:44 +00:00
Marcus Boerger
1e6557f664 Fix implicit_flush 2002-10-02 15:36:29 +00:00
Marcus Boerger
ff51ed7c6f Modified get_status(): Display chunk_size allways and size which is in
most cases initial_size as well as block_size only when used.
2002-10-02 15:10:11 +00:00
Marcus Boerger
d4bba6d158 Revisted Wez patch: chunk_size 0 means cahce the whole output. So
we must apply the default before calling php_enable_output_compression().
I have left the default setting in the rinit function even though i do think
it is not necessary.
2002-10-02 15:02:16 +00:00
Yasuo Ohgaki
e92abff88b Fixed bug #17825. Double zval_ptr_dtor(). 2002-10-01 10:01:56 +00:00
Yasuo Ohgaki
3d8e33f06a Fixed implicit flush. 2002-10-01 02:43:33 +00:00
Yasuo Ohgaki
ecf146cbce Users can shoot themselves by their own output handler always.
Therefore, this check is overkill and it should be documented
limitation, IMO.

Anyway, a little optimization.
2002-09-30 23:46:43 +00:00
Wez Furlong
4356932dfe Fix infinite recursion bug when using zlib output compression.
Cause: the chunk size is taken from the zlib.output_compression setting,
which is 0 or 1.  This causes the block_size for output buffer to be set
to 0 (1 / 2) and thus causes infinite recursion in php_ob_allocate().
Solution: use a value of 0 for the chunk size which will use the default
sizes.  Also add a sanity check which will default the block_size to 1
if it ends up as 0.
2002-09-30 10:18:06 +00:00
Zeev Suraski
85f4abfdac Fix bug #19525 2002-09-23 14:18:42 +00:00
Sebastian Bergmann
714c19fe66 Per discussion on #php.bugs (+1 from at least Derick and Jani), revert double_buffering. 2002-09-01 11:33:19 +00:00
Marcus Boerger
8638bb882f Removed __output_handler as everybody seems against such implicit
behaviour. Instead supply error message.
2002-08-25 14:20:37 +00:00
Marcus Boerger
6d97e0c3eb Use zend_is_callable() instead of php_check_object_method_array() and
drop the latter. THX to Markus Fischer - i did not recognize this function.

@Expanded ob_start() to allow object parameters without methodnames and
@use default method __output_handler(). (Marcus)
2002-08-25 12:16:48 +00:00
Marcus Boerger
08ab630dc7 Reenable array(object,method) in ob_start() 2002-08-25 11:50:25 +00:00
Zeev Suraski
a6e8e72372 Fix ob_gzhandler()'s handling of requests w/o compression but that do have
the Accept-Encoding header
2002-08-23 08:37:35 +00:00
Marcus Boerger
28970b9260 fix warning 2002-08-22 10:52:40 +00:00
Marcus Boerger
5e7a9af062 full decopling of size parameters of ob_start() and internal buffer handlers
#intended behaviour is now fully implemented,
2002-08-21 03:04:17 +00:00
Marcus Boerger
b98c26382f Ignore double_buffering for ob_start(). 2002-08-21 01:00:56 +00:00
Marcus Boerger
8e10659648 Revert ob_start() defaults to 40K/10K until i find a better solution. 2002-08-20 23:23:25 +00:00
Marcus Boerger
2a443b2e77 Changed handling of output buffer sizes.
@Added php.ini option "double_buffering" that forces an additional first
@output buffer and improved handling of buffer sizes. (Marcus)
2002-08-20 19:49:37 +00:00
Marcus Boerger
8b30aeacd8 -use of php_error_docref
-some more information in ob_get_status()
2002-08-19 18:47:23 +00:00
Rasmus Lerdorf
3ffe4cb1ff bool not boolean 2002-08-13 04:37:28 +00:00
Rasmus Lerdorf
34362341e9 Use int, not integer. 2002-08-13 04:31:59 +00:00
Marcus Boerger
21903dfc7e corrected handling of internal output buffers
minor fixs
2002-08-10 16:12:36 +00:00
Marcus Boerger
9c8ba935d6 Improved handling of output buffers (see news)\n#No trim for the string parameter... 2002-08-09 22:29:58 +00:00
Marcus Boerger
6d21c9465d Added php_ob_handler_used to check if a specific output handler is used
in c.
2002-08-05 18:54:53 +00:00
Marcus Boerger
fd26a5c0a9 -New function ob_list_handlers
@- Added ob_list_handlers() which returns an array of all active output
@  handlers. (marcus)
2002-08-05 03:09:42 +00:00
Zeev Suraski
2369533bf9 Remove redundant code (thanks to Jani for pointing that out) 2002-05-12 22:17:58 +00:00
Yasuo Ohgaki
2b5beee5ad Added estrdup() needed.
Fixed typo.
2002-05-08 11:44:14 +00:00
Zeev Suraski
fe127f93de We shouldn't force Content-length:, but much worse, it's wrong in many
cases (basically, unless you use output buffering to buffer all of your content,
it won't work;  output buffering is used for lots of different things as a
functional interface, and such buffers have no relation to Content-type at
all).
2002-05-04 23:23:16 +00:00
Sascha Schumann
707b8b019e Free string before overwriting it 2002-05-04 19:06:46 +00:00
Sascha Schumann
9743860d35 simplify handling of variables by maintaining two strings which
are simply appended instead of traversing the hash table on each
URL/form.

also fix an unconditional segfault in rshutdown due to efree'ing
a static char *.

remove remove_var, add reset_vars.  move the function declarations
into the right header file.
2002-05-04 18:33:13 +00:00
Yasuo Ohgaki
ae828233fe Forgot to dup strings. 2002-05-04 10:55:08 +00:00
Yasuo Ohgaki
b1b5e42251 Fixed reference to freed zval string value. 2002-05-04 09:46:44 +00:00
Yasuo Ohgaki
dfc48de0cb Fixed crash when buffer is over written in ob callback. (Bug $ 12227)
Added check current output function check for Centent-Length header.
@ Fixed output buffer crash when buffer is over written in callback. (Yasuo)
2002-05-04 03:02:51 +00:00
Thies C. Arntzen
9712a4b3c8 @ - Added output_add_rewrite_var() and output_remove_rewrite_var() to inject
@   and remove variables from the URL-Rewriter. (thies)
i have also modified the session module to use this - so it doesn't
need to fiddle with the output-system any more
2002-05-03 08:00:41 +00:00