thetaphi Fri Oct 31 12:32:05 2003 EDT
Modified files: (Branch: PHP_4_3)
/php-src/sapi/nsapi nsapi.c
Log:
MFH
Index: php-src/sapi/nsapi/nsapi.c
diff -u php-src/sapi/nsapi/nsapi.c:1.28.2.22 php-src/sapi/nsapi/nsapi.c:1.28.2.23
--- php-src/sapi/nsapi/nsapi.c:1.28.2.22 Fri Oct 31 07:17:43 2003
+++ php-src/sapi/nsapi/nsapi.c Fri Oct 31 12:32:04 2003
@@ -17,7 +17,7 @@
+----------------------------------------------------------------------+
*/
-/* $Id: nsapi.c,v 1.28.2.22 2003/10/31 12:17:43 thetaphi Exp $ */
+/* $Id: nsapi.c,v 1.28.2.23 2003/10/31 17:32:04 thetaphi Exp $ */
/*
* PHP includes
@@ -208,7 +208,7 @@
NULL,
NULL,
PHP_MINFO(nsapi),
- "$Revision: 1.28.2.22 $",
+ "$Revision: 1.28.2.23 $",
STANDARD_MODULE_PROPERTIES
};
/* }}} */
@@ -491,12 +491,15 @@
param_free(pblock_remove("content-type", rc->rq->srvhdrs));
pblock_nvinsert("content-type", header_content, rc->rq->srvhdrs);
} else {
+ /* to lower case because NSAPI reformats the headers and wants
lowercase */
+ for (p=header_name; *p; p++) {
+ *p=tolower(*p);
+ }
+ if (sapi_header->replace) param_free(pblock_remove(header_name,
rc->rq->srvhdrs));
pblock_nvinsert(header_name, header_content, rc->rq->srvhdrs);
}
- *p = ':'; /* restore '*p' */
-
- efree(sapi_header->header);
+ sapi_free_header(sapi_header);
return 0; /* don't use the default SAPI mechanism, NSAPI duplicates this
functionality */
}
@@ -506,10 +509,6 @@
int retval;
nsapi_request_context *rc = (nsapi_request_context *)SG(server_context);
- /*
- * We could probably just do this in the header_handler. But, I
- * don't know what the implication of doing it there is.
- */
if (SG(sapi_headers).send_default_content_type) {
char *hd;
param_free(pblock_remove("content-type", rc->rq->srvhdrs));
--
PHP CVS Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php