summaryrefslogtreecommitdiff
path: root/ext/zlib/zlib.c
diff options
context:
space:
mode:
authorRasmus Lerdorf <rasmus@php.net>2003-05-21 17:02:40 +0000
committerRasmus Lerdorf <rasmus@php.net>2003-05-21 17:02:40 +0000
commit18954d8bd2b96eed14c0f83cb2dac4f3be549f0e (patch)
treecc48c363ac14250c0d184dae3d78a303929f9b73 /ext/zlib/zlib.c
parent8d5c30c14b16de37823662804dfd5040ee503f44 (diff)
downloadphp-git-18954d8bd2b96eed14c0f83cb2dac4f3be549f0e.tar.gz
Remove bogus commit here too
Diffstat (limited to 'ext/zlib/zlib.c')
-rw-r--r--ext/zlib/zlib.c21
1 files changed, 0 insertions, 21 deletions
diff --git a/ext/zlib/zlib.c b/ext/zlib/zlib.c
index 5c7f4da348..1e6ce2f286 100644
--- a/ext/zlib/zlib.c
+++ b/ext/zlib/zlib.c
@@ -45,7 +45,6 @@
#include "safe_mode.h"
#include "ext/standard/php_standard.h"
#include "ext/standard/info.h"
-#include "ext/standard/php_smart_str.h"
#include "php_zlib.h"
#include "fopen_wrappers.h"
#if HAVE_PWD_H
@@ -75,22 +74,6 @@
#define GZIP_HEADER_LENGTH 10
#define GZIP_FOOTER_LENGTH 8
-#define ADD_CL_HEADER(xln) \
-{ \
- smart_str str = {0}; \
- sapi_header_line ctr = {0}; \
- \
- smart_str_appends(&str, "Content-Length: "); \
- smart_str_append_long(&str, xln); \
- smart_str_0(&str); \
- \
- ctr.line = str.c; \
- ctr.line_len = str.len; \
- \
- sapi_header_op(SAPI_HEADER_REPLACE, &ctr TSRMLS_CC); \
- smart_str_free(&str); \
-}
-
/* True globals, no need for thread safety */
static int gz_magic[2] = {0x1f, 0x8b}; /* gzip magic header */
@@ -1030,8 +1013,6 @@ PHP_FUNCTION(ob_gzhandler)
if (return_original) {
zval_dtor(return_value);
- } else if(do_start && do_end) {
- ADD_CL_HEADER(Z_STRLEN_P(return_value));
}
} else {
@@ -1059,8 +1040,6 @@ static void php_gzip_output_handler(char *output, uint output_len, char **handle
do_end = (mode & PHP_OUTPUT_HANDLER_END ? 1 : 0);
if (php_deflate_string(output, output_len, handled_output, handled_output_len, ZLIBG(ob_gzip_coding), do_start, do_end, ZLIBG(output_compression_level) TSRMLS_CC) != SUCCESS) {
zend_error(E_ERROR, "Compression failed");
- } else if (do_start && do_end) {
- ADD_CL_HEADER(*handled_output_len);
}
}
}