question on mbuf(m_copyback) code
Swami Pichumani
swami at cs.utah.edu
Mon Feb 21 21:08:08 PST 2005
Hi all,
I had a question on the m_copyback code (I use pretty old version but feel
this might still be same).
Inside the while(len>0) loop, the first line kinda seems odd. It subtracts
the off (which becomes after first iteration) from m_len(which is supposed
to tell the amount of data in the particular mbuf) to find the free space
i nthe mbuf. This obviously would not work without m_len getting initialized
to MLEN (or MHLEN), which is not the right thing to do (since when an
mbuf has 0 data when initialized and m_len would be zero).
thanks in advance for any comments on this,
-swami
More information about the freebsd-net
mailing list