X-Git-Url: https://git.m6w6.name/?p=m6w6%2Fext-http;a=blobdiff_plain;f=php_http_message_parser.c;h=3e46674cf3dfa728a62b95a2d93f99fcbd4eb315;hp=634a7648642d6a2b3991cbfbf6f717b779430ade;hb=25f0c16244fc5f8b2c9d9bfddab8a541d2521789;hpb=f08f6dfe8fc5a2af698cac626b42de1619ef6332 diff --git a/php_http_message_parser.c b/php_http_message_parser.c index 634a764..3e46674 100644 --- a/php_http_message_parser.c +++ b/php_http_message_parser.c @@ -458,7 +458,7 @@ PHP_HTTP_API php_http_message_parser_state_t php_http_message_parser_parse(php_h len = dec_len; if (php_http_encoding_stream_done(parser->dechunk)) { - cut = buffer->used - PHP_HTTP_BUFFER_LEN(parser->dechunk->ctx); + cut = buffer->used - PHP_HTTP_BUFFER(parser->dechunk->ctx)->used; php_http_message_parser_state_push(parser, 2, PHP_HTTP_MESSAGE_PARSER_STATE_BODY_DONE, PHP_HTTP_MESSAGE_PARSER_STATE_BODY); } else { cut = buffer->used;