[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-exchange] 03/04: add assertion to be more defensive
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-exchange] 03/04: add assertion to be more defensive against buffer overflow (cannot happen, but this better protects against future changes) |
Date: |
Fri, 06 Oct 2017 21:31:17 +0200 |
This is an automated email from the git hooks/post-receive script.
grothoff pushed a commit to branch master
in repository exchange.
commit dc883f8556f34b324dd7677ab21c3d2840fd38a9
Author: Christian Grothoff <address@hidden>
AuthorDate: Fri Oct 6 21:27:58 2017 +0200
add assertion to be more defensive against buffer overflow (cannot happen,
but this better protects against future changes)
---
src/exchange-lib/exchange_api_refresh_link.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/exchange-lib/exchange_api_refresh_link.c
b/src/exchange-lib/exchange_api_refresh_link.c
index 5b2286e..ca55668 100644
--- a/src/exchange-lib/exchange_api_refresh_link.c
+++ b/src/exchange-lib/exchange_api_refresh_link.c
@@ -235,6 +235,7 @@ parse_refresh_link_ok (struct
TALER_EXCHANGE_RefreshLinkHandle *rlh,
/* decode all coins */
for (i=0;i<json_array_size (jsona);i++)
{
+ GNUNET_assert (i + off_coin < num_coins);
if (GNUNET_OK !=
parse_refresh_link_coin (rlh,
json_array_get (jsona,
--
To stop receiving notification emails like this one, please contact
address@hidden