[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[libmicrohttpd] 02/03: postprocessor: added asserts
From: |
gnunet |
Subject: |
[libmicrohttpd] 02/03: postprocessor: added asserts |
Date: |
Wed, 15 Sep 2021 12:51:22 +0200 |
This is an automated email from the git hooks/post-receive script.
karlson2k pushed a commit to branch master
in repository libmicrohttpd.
commit ba63b33aea997cdc94b379d29be203f39a32c4b6
Author: Evgeny Grin (Karlson2k) <k2k@narod.ru>
AuthorDate: Wed Sep 15 13:31:49 2021 +0300
postprocessor: added asserts
---
src/microhttpd/postprocessor.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/microhttpd/postprocessor.c b/src/microhttpd/postprocessor.c
index 0da28141..1e4ce7d0 100644
--- a/src/microhttpd/postprocessor.c
+++ b/src/microhttpd/postprocessor.c
@@ -618,6 +618,7 @@ post_process_urlencoded (struct MHD_PostProcessor *pp,
pp->state = PP_Error;
break;
case PP_Callback:
+ mhd_assert ((NULL != end_key) || (NULL == start_key));
if ( (pp->buffer_pos + (end_key - start_key) >=
pp->buffer_size) ||
(pp->buffer_pos + (end_key - start_key) <
@@ -674,6 +675,7 @@ post_process_urlencoded (struct MHD_PostProcessor *pp,
/* save remaining data for next iteration */
if (NULL != start_key)
{
+ mhd_assert ((PP_Init == pp->state) || (NULL != end_key));
if (NULL == end_key)
end_key = &post_data[poff];
if (pp->buffer_pos + (end_key - start_key) >= pp->buffer_size)
--
To stop receiving notification emails like this one, please contact
gnunet@gnunet.org.