projects
/
m6w6
/
ext-http
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
|
github
raw
|
inline
| side by side
- fix "UNKNOWN" for unknown request methods
[m6w6/ext-http]
/
http_info_api.c
diff --git
a/http_info_api.c
b/http_info_api.c
index 18fea6f1bddbb96272dbe9b5c7ab94f66f6ba035..0e9b6487e941a69a25c5a95ac23f52665b5c1138 100644
(file)
--- a/
http_info_api.c
+++ b/
http_info_api.c
@@
-32,7
+32,8
@@
ZEND_EXTERN_MODULE_GLOBALS(http);
PHP_HTTP_API void _http_info_default_callback(void **nothing, HashTable **headers, http_info *info TSRMLS_DC)
{
zval array;
PHP_HTTP_API void _http_info_default_callback(void **nothing, HashTable **headers, http_info *info TSRMLS_DC)
{
zval array;
- Z_ARRVAL(array) = *headers;
+
+ INIT_ZARR(array, *headers);
switch (info->type)
{
switch (info->type)
{
@@
-81,7
+82,7
@@
PHP_HTTP_API STATUS _http_info_parse_ex(const char *pre_header, http_info *info,
}
/* where's the end of the line */
}
/* where's the end of the line */
- if (!(
(end = strchr(pre_header, '\r')) || (end = strchr(pre_header, '\n')
))) {
+ if (!(
end = http_locate_eol(pre_header, NULL
))) {
end = pre_header + strlen(pre_header);
}
end = pre_header + strlen(pre_header);
}