static inline int php_output_handler_append(php_output_handler *handler, const php_output_buffer *buf TSRMLS_DC)
{
if (buf->used) {
+ OG(flags) |= PHP_OUTPUT_WRITTEN;
/* store it away */
if ((handler->buffer.size - handler->buffer.used) <= buf->used) {
size_t grow_int = PHP_OUTPUT_HANDLER_INITBUF_SIZE(handler->size);
if (OG(flags) & PHP_OUTPUT_IMPLICITFLUSH) {
sapi_flush(TSRMLS_C);
}
+ OG(flags) |= PHP_OUTPUT_SENT;
}
}
php_output_context_dtor(&context);
/* real global flags */
#define PHP_OUTPUT_IMPLICITFLUSH 0x01
#define PHP_OUTPUT_DISABLED 0x02
+#define PHP_OUTPUT_WRITTEN 0x04
+#define PHP_OUTPUT_SENT 0x08
/* supplementary flags for php_output_get_status() */
#define PHP_OUTPUT_ACTIVE 0x10
#define PHP_OUTPUT_LOCKED 0x20
PHPAPI void php_output_discard_all(TSRMLS_D);
PHPAPI int php_output_get_contents(zval *p TSRMLS_DC);
-PHPAPI int php_output_get_length(zval *TSRMLS_DC);
+PHPAPI int php_output_get_length(zval *p TSRMLS_DC);
PHPAPI int php_output_get_level(TSRMLS_D);
PHPAPI int php_output_start_default(TSRMLS_D);