diff --git a/src/ports/STM32Cube/pnal.c b/src/ports/STM32Cube/pnal.c index 7f7d3f6e..a6ac3324 100644 --- a/src/ports/STM32Cube/pnal.c +++ b/src/ports/STM32Cube/pnal.c @@ -299,7 +299,9 @@ pnal_buf_t * pnal_buf_alloc (uint16_t length) void pnal_buf_free (pnal_buf_t * p) { - CC_ASSERT (pbuf_free (p) == 1); + u8_t ret = pbuf_free (p); + CC_UNUSED (ret); + CC_ASSERT (ret == 1); } uint8_t pnal_buf_header (pnal_buf_t * p, int16_t header_size_increment) diff --git a/src/ports/iMX8M/pnal.c b/src/ports/iMX8M/pnal.c index cf1efaad..9a5d2343 100644 --- a/src/ports/iMX8M/pnal.c +++ b/src/ports/iMX8M/pnal.c @@ -176,7 +176,9 @@ pnal_buf_t * pnal_buf_alloc (uint16_t length) void pnal_buf_free (pnal_buf_t * p) { - CC_ASSERT (pbuf_free (p) == 1); + u8_t ret = pbuf_free (p); + CC_UNUSED (ret); + CC_ASSERT (ret == 1); } uint8_t pnal_buf_header (pnal_buf_t * p, int16_t header_size_increment) diff --git a/src/ports/rt-kernel/pnal.c b/src/ports/rt-kernel/pnal.c index 214ef7bf..aae7f007 100644 --- a/src/ports/rt-kernel/pnal.c +++ b/src/ports/rt-kernel/pnal.c @@ -368,8 +368,10 @@ pnal_buf_t * pnal_buf_alloc (uint16_t length) } void pnal_buf_free (pnal_buf_t * p) -{ - ASSERT (pbuf_free (p) == 1); +{ + u8_t ret = pbuf_free (p); + (void)ret; + ASSERT (ret == 1); } uint8_t pnal_buf_header (pnal_buf_t * p, int16_t header_size_increment)