'\"macro stdmacro
.if n .pH ddi_dki.dupmsg @(#)dupmsg	40.6 of 10/10/89
.\" Copyright 1989 AT&T
.de IX
.ie '\\n(.z'' .tm .Index: \\$1 \\$2 \\$3 \\$4 \\$5 \\$6 \\$7 \\$8 \\$9	\\n%
.el \\!.IX \\$1 \\$2 \\$3 \\$4 \\$5 \\$6 \\$7 \\$8 \\$9
..
.nr X
.if \nX=0 .ds x} dupmsg D3DK "STREAMS" "DDI/DKI" "\&"
.if \nX=1 .ds x} dupmsg D3DK "STREAMS" "DDI/DKI"
.if \nX=2 .ds x} dupmsg D3DK "" "\&"
.if \nX=3 .ds x} dupmsg "" "" "\&"
.TH \*(x}
.IX "\f4dupmsg\fP(D3DK)"
.IX "STREAMS message blocks"
.SH NAME
\f4dupmsg\f1 \- duplicate a message
.SH SYNOPSIS
.nf
.na
\f4#include <sys/stream.h>
.sp 0.5
mblk_t *dupmsg(mblk_t *\f2mp\f4);\f1
.ad
.fi
.SH ARGUMENTS
.RS 0n 10
.IP "\f2mp\f1" 10n
Pointer to the message block.
.RE
.SH DESCRIPTION
\f4dupmsg\f1 forms a new message by copying the message block descriptors
pointed to by \f2mp\f1 and linking them.
\f4dupb\f1(D3DK) is called for each message block.
The data blocks themselves are not duplicated.
.SH RETURN VALUE
If successful, \f4dupmsg\f1 returns a pointer to the new message block.
Otherwise, it returns a \f4NULL\f1 pointer.
.SH LEVEL
Base or Interrupt
.SH SEE ALSO
\f2BCI Driver Development Guide\f1, Chapter 7, ``STREAMS''
.P
.na
\f4copyb\f1(D3DK),
\f4copymsg\f1(D3DK),
\f4dupb\f1(D3DK)
.ad
.SH EXAMPLE
See the \f4copyb\f1(D3DK) function page for an example of \f4dupmsg\f1.
