From f98c3dd4b5186dd1a5f8c2e14fcc3154f8a2068c Mon Sep 17 00:00:00 2001 From: sg Date: Thu, 21 Jul 2016 21:54:13 +0200 Subject: [PATCH] LWIP_MPU_COMPATIBLE: help dumb compilers to see 'msg' is used (MSVC :( --- src/api/api_lib.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/api/api_lib.c b/src/api/api_lib.c index 32f67090..82da791a 100644 --- a/src/api/api_lib.c +++ b/src/api/api_lib.c @@ -445,6 +445,9 @@ netconn_recv_data(struct netconn *conn, void **new_buf) err_t err; #if LWIP_TCP API_MSG_VAR_DECLARE(msg); +#if LWIP_MPU_COMPATIBLE + msg = NULL; +#endif #endif /* LWIP_TCP */ LWIP_ERROR("netconn_recv: invalid pointer", (new_buf != NULL), return ERR_ARG;); @@ -479,7 +482,7 @@ netconn_recv_data(struct netconn *conn, void **new_buf) API_MSG_VAR_ALLOC(msg); } #endif /* LWIP_TCP */ - + #if LWIP_SO_RCVTIMEO if (sys_arch_mbox_fetch(&conn->recvmbox, &buf, conn->recv_timeout) == SYS_ARCH_TIMEOUT) { #if LWIP_TCP