lwip-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[lwip-devel] [patch #7088] Support for mem_realloc moving memory


From: Kieran Mansley
Subject: [lwip-devel] [patch #7088] Support for mem_realloc moving memory
Date: Thu, 18 Feb 2010 20:30:15 +0000
User-agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10_6_2; en-us) AppleWebKit/531.21.8 (KHTML, like Gecko) Version/4.0.4 Safari/531.21.10

Follow-up Comment #11, patch #7088 (project lwip):

It seems like a big part of this bug is the expectation  that the lwIP
mem_realloc function is like the normal realloc function, when in fact it is
much more limited, and at least some of this limitation is by design. Had it
been called something else, like mem_trim() this confusion would likely not
have arisen.

At the moment I'm not convinced there is any advantage to changing the stack
and the interface to support potentially moving the data: there is no
requirement in the stack for this feature.  It seems like changing the
abilities of the mem_realloc function would introduce bugs into the stack
(i.e. places where it is assumed that mem_realloc doesn't move the memory) and
we'd just be making extra work.

The justification that this would allow people to use a general purpose
realloc function as customisation instead of the lwIP-supplied realloc is an
interesting one.  Would this result in any improvement?  I'd not considered
that people would want to customise this function.  Can you outline a benefit
in doing so?

    _______________________________________________________

Reply to this item at:

  <http://savannah.nongnu.org/patch/?7088>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.nongnu.org/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]