mirror of
https://git.gnunet.org/libmicrohttpd.git
synced 2026-09-25 04:09:31 +03:00
fix overflow check
This commit is contained in:
@@ -532,7 +532,8 @@ post_process_urlencoded (struct MHD_PostProcessor *pp,
|
||||
mhd_assert (end_key >= start_key);
|
||||
key_len = (size_t) (end_key - start_key);
|
||||
mhd_assert (0 != key_len); /* it must be always non-zero here */
|
||||
if (pp->buffer_pos + key_len >= pp->buffer_size)
|
||||
if ( (pp->buffer_pos + key_len >= pp->buffer_size) ||
|
||||
(pp->buffer_pos + key_len < pp->buffer_pos) )
|
||||
{
|
||||
pp->state = PP_Error;
|
||||
return MHD_NO;
|
||||
|
||||
Reference in New Issue
Block a user