Removed warning "empty body in an if statement" in tcp_receive() for LWIP_DEBUG=0

This commit is contained in:
goldsimon 2007-06-18 20:08:31 +00:00
parent f66bbda8b1
commit c9ebb895a1

View File

@ -939,14 +939,16 @@ tcp_receive(struct tcp_pcb *pcb)
p->len = 0; p->len = 0;
p = p->next; p = p->next;
} }
if(pbuf_header(p, -off)) if(pbuf_header(p, -off)) {
/* Do we need to cope with this failing? Assert for now */ /* Do we need to cope with this failing? Assert for now */
LWIP_ASSERT("pbuf_header failed", 0); LWIP_ASSERT("pbuf_header failed", 0);
}
} else { } else {
if(pbuf_header(inseg.p, -off)) if(pbuf_header(inseg.p, -off)) {
/* Do we need to cope with this failing? Assert for now */ /* Do we need to cope with this failing? Assert for now */
LWIP_ASSERT("pbuf_header failed", 0); LWIP_ASSERT("pbuf_header failed", 0);
} }
}
/* KJM following line changed to use p->payload rather than inseg->p->payload /* KJM following line changed to use p->payload rather than inseg->p->payload
to fix bug #9076 */ to fix bug #9076 */
inseg.dataptr = p->payload; inseg.dataptr = p->payload;