MBLKL(mp) is merely the difference between mp->b_wptr and mp->b_rptr, which is state usually specific to usage of a particular *instance* of a STREAMS message buffer. Such state is not copied across by copymsg(). Think of copymsg() as dupmsg() but with a duplicate dblk_t rather than a reference to the original.
Paul On 22 October 2010 05:15, Saadia Fatima <saadiafat...@yahoo.com> wrote: > Hi > > When I copy a message block (mblk_t, with a non-zero length) using copymsg, > the value returned by MBLKL for the copy is zero. > > len = MBLKL(m); //say 80 > mc = copymsg(m); > len = MBLKL(mc);// returns 0 ??? > > > -sf > -- > This message posted from opensolaris.org > _______________________________________________ > opensolaris-code mailing list > opensolaris-code@opensolaris.org > http://mail.opensolaris.org/mailman/listinfo/opensolaris-code > -- Paul Durrant http://www.linkedin.com/in/pdurrant _______________________________________________ opensolaris-code mailing list opensolaris-code@opensolaris.org http://mail.opensolaris.org/mailman/listinfo/opensolaris-code