From c61262d8397ac31fb9f71ec7265c40469fe4e984 Mon Sep 17 00:00:00 2001 From: fbernon Date: Fri, 4 Jan 2008 23:24:05 +0000 Subject: [PATCH] Minor changes in lwip folder: fix some warnings. --- src/core/pbuf.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/core/pbuf.c b/src/core/pbuf.c index 1442f243..c176adbe 100644 --- a/src/core/pbuf.c +++ b/src/core/pbuf.c @@ -307,7 +307,8 @@ pbuf_realloc(struct pbuf *p, u16_t new_len) /* (other types merely adjust their length fields */ if ((q->type == PBUF_RAM) && (rem_len != q->len)) { /* reallocate and adjust the length of the pbuf that will be split */ - mem_realloc(q, (u8_t *)q->payload - (u8_t *)q + rem_len); + q = mem_realloc(q, (u8_t *)q->payload - (u8_t *)q + rem_len); + LWIP_ASSERT("mem_realloc give q == NULL", q != NULL); } /* adjust length fields for new last pbuf */ q->len = rem_len;