Added some more asserts to check that pcb->state != LISTEN

This commit is contained in:
goldsimon
2011-06-26 17:07:13 +00:00
parent d0026793bf
commit 4444db2990
2 changed files with 16 additions and 1 deletions

View File

@@ -901,6 +901,10 @@ tcp_output(struct tcp_pcb *pcb)
s16_t i = 0;
#endif /* TCP_CWND_DEBUG */
/* pcb->state LISTEN not allowed here */
LWIP_ASSERT("don't call tcp_output for listen-pcbs",
pcb->state != LISTEN);
/* First, check if we are invoked by the TCP input processing
code. If so, we do not output anything. Instead, we rely on the
input processing code to call us when input processing is done