lwip-users
[Top][All Lists]
Advanced

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

[lwip-users] Re: [lwip] pbuf_realloc of ROM pbufs


From: Adam Dunkels
Subject: [lwip-users] Re: [lwip] pbuf_realloc of ROM pbufs
Date: Thu, 09 Jan 2003 00:08:16 -0000

Hi!

On Thu, 2002-07-25 at 16:32, Kieran Mansley wrote:
> When pbuf_realloc is called for PBUF_ROM type pbufs, it treats them
> differently to PBUF_RAM or PBUF_POOL.  In particular, it assumes the pbuf
> is not part of a chain.  To perform the realloc it simply updates the len
> and tot_len fields.  Surely it should, as with the other types, navigate
> to the point in the chain at which the change will take place, and alter
> the "len" field of that pbuf?
> 
> I can't see any particular reason why you wouldn't have chains of ROM
> pbufs.  Can anyone else see a problem with it?

I don't see any reason to not have PBUF_ROM chains - you are right in
that it should be a check in there!

The same goes for your other comment. Especially RAM and ROM pbufs are
chained together quite a lot (in the TCP output code for instance). POOL
pbufs are not chained with any other pbuf type, though (and I quite
frankly don't see any immediate reason for doing so either).

/adam
-- 
Adam Dunkels <address@hidden>
http://www.dunkels.com/adam/

[This message was sent through the lwip discussion list.]




reply via email to

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