From: Guus Sliepen Date: Thu, 31 Oct 2019 19:41:04 +0000 (+0100) Subject: Avoid a compiler warning when compiling with -DNDEBUG. X-Git-Url: https://git.meshlink.io/?a=commitdiff_plain;h=19f3f4462c52eaa766ab76ce671921f0e4dc4ebd;p=utcp Avoid a compiler warning when compiling with -DNDEBUG. --- diff --git a/utcp.c b/utcp.c index 802d95a..c57a5cc 100644 --- a/utcp.c +++ b/utcp.c @@ -1314,8 +1314,10 @@ synack: assert(data_acked >= 0); +#ifndef NDEBUG int32_t bufused = seqdiff(c->snd.last, c->snd.una); assert(data_acked <= bufused); +#endif if(data_acked) { buffer_get(&c->sndbuf, NULL, data_acked);