[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/una
From: |
Jonathan Larmour |
Subject: |
[lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue |
Date: |
Wed, 28 Mar 2007 10:16:47 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.8.0.10) Gecko/20070223 Fedora/1.5.0.10-1.fc5 Firefox/1.5.0.10 |
Follow-up Comment #35, bug #11400 (project lwip):
Hmmm, oh dear it looks like you're right. I hadn't thought there would be a
problem because I assumed the ref count would sort it out. But the API
contract with the user is not like that. This issue - whether chains survive
a call - is exactly the same as with TCP, where it may get put on a queue.
But in that case there is a "copy" flag (originating from netconn_write) to
indicate what should be done. By the time the code path reaches ARP, that
information is lost. And in the case of UDP and netconn_send, it never
existed.
So unless we change the UDP raw API to also have a 'copy' flag, and then pass
that around (or perhaps better, add in a new different pbuf flag e.g.
PBUF_FLAG_COPY). At which point it clearly becomes far too much effort, so
Simon's pbuf_copy() implementation _is_ probably the best thing to do right
now after all. We should consider changing the API for the future to allow
this optimisation.
About the last question and pbuf_ref. Yes you must not call pbuf_free(b). And
there's a lot of API stuff which should be pointed out more clearly IMHO!
_______________________________________________________
Reply to this item at:
<http://savannah.nongnu.org/bugs/?11400>
_______________________________________________
Message sent via/by Savannah
http://savannah.nongnu.org/
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, (continued)
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Simon Goldschmidt, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Jonathan Larmour, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Kieran Mansley, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Jonathan Larmour, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Kieran Mansley, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Jonathan Larmour, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Kieran Mansley, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Jonathan Larmour, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Simon Goldschmidt, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Simon Goldschmidt, 2007/03/26
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue,
Jonathan Larmour <=
- [lwip-devel] [bug #11400] ARP multi-packet-queue modifies TCP unsent/unacked segment packet pbuf chain into packet queue, Simon Goldschmidt, 2007/03/28