mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2024-10-02 12:52:10 +00:00
Fixed bug #26236: "TCP options (timestamp) don't work with no-copy-tcpwrite": deallocate option data, only concat segments with same flags
This commit is contained in:
parent
542b8fffb1
commit
ed65d9cd75
@ -83,6 +83,10 @@ HISTORY
|
|||||||
|
|
||||||
++ Bugfixes:
|
++ Bugfixes:
|
||||||
|
|
||||||
|
2009-04-19 Simon Goldschmidt
|
||||||
|
* tcp_out.c: Fixed bug #26236: "TCP options (timestamp) don't work with
|
||||||
|
no-copy-tcpwrite": deallocate option data, only concat segments with same flags
|
||||||
|
|
||||||
2009-04-19 Simon Goldschmidt
|
2009-04-19 Simon Goldschmidt
|
||||||
* tcp_out.c: Fixed bug #25094: "Zero-length pbuf" (options are now allocated
|
* tcp_out.c: Fixed bug #25094: "Zero-length pbuf" (options are now allocated
|
||||||
in the header pbuf, not the data pbuf)
|
in the header pbuf, not the data pbuf)
|
||||||
|
@ -344,9 +344,11 @@ tcp_enqueue(struct tcp_pcb *pcb, void *arg, u16_t len,
|
|||||||
!(TCPH_FLAGS(useg->tcphdr) & (TCP_SYN | TCP_FIN)) &&
|
!(TCPH_FLAGS(useg->tcphdr) & (TCP_SYN | TCP_FIN)) &&
|
||||||
!(flags & (TCP_SYN | TCP_FIN)) &&
|
!(flags & (TCP_SYN | TCP_FIN)) &&
|
||||||
/* fit within max seg size */
|
/* fit within max seg size */
|
||||||
useg->len + queue->len <= pcb->mss) {
|
(useg->len + queue->len <= pcb->mss) &&
|
||||||
|
/* only concatenate segments with the same options */
|
||||||
|
(useg->flags == queue->flags)) {
|
||||||
/* Remove TCP header from first segment of our to-be-queued list */
|
/* Remove TCP header from first segment of our to-be-queued list */
|
||||||
if(pbuf_header(queue->p, -TCP_HLEN)) {
|
if(pbuf_header(queue->p, -(TCP_HLEN + optlen))) {
|
||||||
/* Can we cope with this failing? Just assert for now */
|
/* Can we cope with this failing? Just assert for now */
|
||||||
LWIP_ASSERT("pbuf_header failed\n", 0);
|
LWIP_ASSERT("pbuf_header failed\n", 0);
|
||||||
TCP_STATS_INC(tcp.err);
|
TCP_STATS_INC(tcp.err);
|
||||||
|
Loading…
Reference in New Issue
Block a user