summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDmitry Stogov <dmitry@php.net>2011-11-23 10:49:42 +0000
committerDmitry Stogov <dmitry@php.net>2011-11-23 10:49:42 +0000
commit48a5ab0eca74ad6306b71cfe6868b7a490474adc (patch)
tree1580ea5682c6be080b406df3cc2822ea7ef0af92
parentb6137f4cb10bcf0a86a743077363375a01dfd6a5 (diff)
downloadphp-git-48a5ab0eca74ad6306b71cfe6868b7a490474adc.tar.gz
Fixed bug #48216 (PHP Fatal error: SOAP-ERROR: Parsing WSDL: Extra content at the end of the doc, when server uses chunked transfer encoding with spaces after chunk size)
-rw-r--r--NEWS3
-rw-r--r--ext/standard/filters.c10
2 files changed, 4 insertions, 9 deletions
diff --git a/NEWS b/NEWS
index 384796735e..5999d3c968 100644
--- a/NEWS
+++ b/NEWS
@@ -66,6 +66,9 @@ PHP NEWS
is >0). (Ilia)
- SOAP
+ . Fixed bug #48216 (PHP Fatal error: SOAP-ERROR: Parsing WSDL:
+ Extra content at the end of the doc, when server uses chunked transfer
+ encoding with spaces after chunk size). (Dmitry)
. Fixed bug #44686 (SOAP-ERROR: Parsing WSDL with references). (Dmitry)
- Tidy:
diff --git a/ext/standard/filters.c b/ext/standard/filters.c
index 2f1e3dc706..ce241933db 100644
--- a/ext/standard/filters.c
+++ b/ext/standard/filters.c
@@ -1897,7 +1897,6 @@ php_stream_filter_factory consumed_filter_factory = {
typedef enum _php_chunked_filter_state {
CHUNK_SIZE_START,
CHUNK_SIZE,
- CHUNK_SIZE_EXT_START,
CHUNK_SIZE_EXT,
CHUNK_SIZE_CR,
CHUNK_SIZE_LF,
@@ -1937,7 +1936,7 @@ static int php_dechunk(char *buf, int len, php_chunked_filter_data *data)
data->state = CHUNK_ERROR;
break;
} else {
- data->state = CHUNK_SIZE_EXT_START;
+ data->state = CHUNK_SIZE_EXT;
break;
}
data->state = CHUNK_SIZE;
@@ -1948,13 +1947,6 @@ static int php_dechunk(char *buf, int len, php_chunked_filter_data *data)
} else if (p == end) {
return out_len;
}
- case CHUNK_SIZE_EXT_START:
- if (*p == ';'|| *p == '\r' || *p == '\n') {
- data->state = CHUNK_SIZE_EXT;
- } else {
- data->state = CHUNK_ERROR;
- continue;
- }
case CHUNK_SIZE_EXT:
/* skip extension */
while (p < end && *p != '\r' && *p != '\n') {