Re: mbuf data access (repost)
Re: mbuf data access (repost)
- Subject: Re: mbuf data access (repost)
- From: Anton Kuzmin <email@hidden>
- Date: Tue, 13 Jun 2006 22:21:46 +0100
As I understand, there's one caveat with mbuf_dup: if it's an mbuf on
the input path from a network device driver, the data pointer (and
length) should be temporarily adjusted to point to the media header,
otherwise mbuf_dup doesn't copy it across, which might be useful if
there's a need to inject the copy back into the input path.
Anton
Josh Graessley wrote:
Peter is correct. You can use mbuf_mclhasreference to determine if you
need to copy the mbuf before modifying the data.
To make the copy, you can use mbuf_dup.
-josh
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-kernel mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden