From c4ff244c4e3d1b4d24938b4a7917ec866d9e929b Mon Sep 17 00:00:00 2001 From: davidhaas Date: Fri, 28 Mar 2003 19:45:37 +0000 Subject: [PATCH] Fixed minor compile issues. --- src/core/pbuf.c | 7 +++---- src/include/lwip/debug.h | 2 +- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/src/core/pbuf.c b/src/core/pbuf.c index 5f443ea6..1016087a 100644 --- a/src/core/pbuf.c +++ b/src/core/pbuf.c @@ -625,7 +625,6 @@ pbuf_free(struct pbuf *p) { struct pbuf *q; u8_t count = 0; - u16_t last_ref_count; SYS_ARCH_DECL_PROTECT(old_level); if (p == NULL) { @@ -781,7 +780,7 @@ pbuf_chain(struct pbuf *h, struct pbuf *t) #if PBUF_CHAIN_DOES_REFER /** TODO (WORK IN PROGRESS) */ /* t is now referenced to one more time */ pbuf_ref(t); - DEBUGF(DEBUG_PBUF | DBG_FRESH | 2, ("pbuf_chain: referencing %p\n", q)); + DEBUGF(PBUF_DEBUG | DBG_FRESH | 2, ("pbuf_chain: referencing %p\n", (void *) t)); #endif } @@ -811,7 +810,7 @@ pbuf_dechain(struct pbuf *p) #if PBUF_CHAIN_DOES_REFER /** TODO (WORK IN PROGRESS) */ /* q is no longer referenced by p */ pbuf_free(q); - DEBUGF(DEBUG_PBUF | DBG_FRESH | 2, ("pbuf_dechain: unreferencing %p\n", q)); + DEBUGF(PBUF_DEBUG | DBG_FRESH | 2, ("pbuf_dechain: unreferencing %p\n", (void *) q)); #endif return q; } @@ -878,7 +877,7 @@ pbuf_take(struct pbuf *f) q->len = p->len; /* do not copy ref, since someone else might be using the old buffer */ /* pbuf is not freed, as this is the responsibility of the application */ - DEBUGF(PBUF_DEBUG, ("pbuf_take: replaced PBUF_REF %p with %q\n", (void *)p, (void *)q)); + DEBUGF(PBUF_DEBUG, ("pbuf_take: replaced PBUF_REF %p with %p\n", (void *)p, (void *)q)); p = q; } else diff --git a/src/include/lwip/debug.h b/src/include/lwip/debug.h index cbd80387..2aa70710 100644 --- a/src/include/lwip/debug.h +++ b/src/include/lwip/debug.h @@ -66,7 +66,7 @@ /** print debug message only if debug message type is enabled... * AND is of correct type AND is at least DBG_LEVEL */ -# define DEBUGF(debug, x) do { if (((debug) & DBG_ON) && ((debug) & DBG_TYPES_ON) && (((debug) & DBG_MASK_LEVEL) >= DBG_MIN_LEVEL)) { LWIP_PLATFORM_DIAG(x); if (debug & DBG_HALT) while(1); } } while(0) +# define DEBUGF(debug, x) do { if (((debug) & DBG_ON) && ((debug) & DBG_TYPES_ON) && (((debug) & DBG_MASK_LEVEL) >= DBG_MIN_LEVEL)) { LWIP_PLATFORM_DIAG(x); if ((debug) & DBG_HALT) while(1); } } while(0) # define LWIP_ERROR(x) do { LWIP_PLATFORM_DIAG(x); } while(0) #else /* LWIP_DEBUG */ # define LWIP_ASSERT(x, y)