mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
fix signed/unsigned mismatch warning
This commit is contained in:
parent
3942ed52be
commit
6075e5a549
1 changed files with 5 additions and 2 deletions
|
@ -1431,7 +1431,9 @@ size_t php_http_parser_execute (php_http_parser *parser,
|
|||
}
|
||||
|
||||
case s_body_identity:
|
||||
to_read = MIN(pe - p, (size_t)parser->content_length);
|
||||
assert(pe >= p);
|
||||
|
||||
to_read = MIN((size_t)(pe - p), (size_t)parser->content_length);
|
||||
if (to_read > 0) {
|
||||
if (settings->on_body) settings->on_body(parser, p, to_read);
|
||||
p += to_read - 1;
|
||||
|
@ -1515,8 +1517,9 @@ size_t php_http_parser_execute (php_http_parser *parser,
|
|||
case s_chunk_data:
|
||||
{
|
||||
assert(parser->flags & F_CHUNKED);
|
||||
assert(pe >= p);
|
||||
|
||||
to_read = MIN(pe - p, (size_t)(parser->content_length));
|
||||
to_read = MIN((size_t)(pe - p), (size_t)(parser->content_length));
|
||||
|
||||
if (to_read > 0) {
|
||||
if (settings->on_body) settings->on_body(parser, p, to_read);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue