diff options
author | Sascha Schumann <sas@php.net> | 2000-10-26 18:18:21 +0000 |
---|---|---|
committer | Sascha Schumann <sas@php.net> | 2000-10-26 18:18:21 +0000 |
commit | 2b060b3bf3018ae8db824d2a87bb8cefb591d059 (patch) | |
tree | b49eb2ebafe65e82b6725e75a8d04edc0e80bbd2 /main/SAPI.c | |
parent | 52e45f514bab566175d520c99c67a819734c2d67 (diff) | |
download | php-git-2b060b3bf3018ae8db824d2a87bb8cefb591d059.tar.gz |
Add sapi_add_header_ex, which lets you specify whether you want
to add or replace a header.
Diffstat (limited to 'main/SAPI.c')
-rw-r--r-- | main/SAPI.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/main/SAPI.c b/main/SAPI.c index afe98f35c7..563f1cd072 100644 --- a/main/SAPI.c +++ b/main/SAPI.c @@ -356,7 +356,7 @@ static int sapi_extract_response_code(const char *header_line) /* This function expects a *duplicated* string, that was previously emalloc()'d. * Pointers sent to this functions will be automatically freed by the framework. */ -SAPI_API int sapi_add_header(char *header_line, uint header_line_len, zend_bool duplicate) +SAPI_API int sapi_add_header_ex(char *header_line, uint header_line_len, zend_bool duplicate, zend_bool replace) { int retval, free_header = 0; sapi_header_struct sapi_header; @@ -390,6 +390,7 @@ SAPI_API int sapi_add_header(char *header_line, uint header_line_len, zend_bool sapi_header.header = header_line; sapi_header.header_len = header_line_len; + sapi_header.replace = replace; /* Check the header for a few cases that we have special support for in SAPI */ if (header_line_len>=5 |