2 .\" Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved
3 .\" The contents of this file are subject to the terms of the Common Development and Distribution License (the "License"). You may not use this file except in compliance with the License.
4 .\" You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE or http://www.opensolaris.org/os/licensing. See the License for the specific language governing permissions and limitations under the License.
5 .\" When distributing Covered Code, include this CDDL HEADER in each file and include the License file at usr/src/OPENSOLARIS.LICENSE. If applicable, add the following below this CDDL HEADER, with the fields enclosed by brackets "[]" replaced with your own identifying information: Portions Copyright [yyyy] [name of copyright owner]
6 .TH SIP_COPY_START_LINE 3SIP "Jan 25, 2007"
8 sip_copy_start_line, sip_copy_header, sip_copy_header_by_name,
9 sip_copy_all_headers \- copy headers from a SIP message
13 \fBcc\fR [ \fIflag\fR ... ] \fIfile\fR ... \fB-lsip\fR [ \fIlibrary\fR ... ]
16 \fBint\fR \fIsip_copy_start_line\fR(\fBsip_msg_t\fR \fIfrom_msg\fR, \fBsip_msg_t\fR \fIto_msg\fR);
21 \fBint\fR \fIsip_copy_header\fR(\fBsip_msg_t\fR \fIsip_msg\fR, \fBsip_header_t\fR \fIsip_header\fR,
22 \fBchar *\fR\fIparam\fR);
27 \fBint\fR \fIsip_copy_header_by_name\fR(\fBsip_msg_t\fR \fIfrom_msg\fR, \fBsip_msg_t\fR \fIto_msg\fR,
28 \fBchar *\fR\fIheader_name\fR, \fBchar *\fR\fIparam\fR);
33 \fBint\fR \fIsip_copy_all_headers\fR(\fBsip_msg_t\fR \fIfrom_msg\fR, \fBsip_msg_t\fR \fIto_msg\fR);
39 The \fBsip_copy_start_line()\fR function copies the start line, a request or a
40 response line, from \fIfrom_msg\fR to \fIto_msg\fR.
43 The \fBsip_copy_header()\fR function copies the \fBSIP\fR header specified by
44 \fIsip_header\fR to the \fBSIP\fR message \fIsip_msg\fR. A new \fBSIP\fR header
45 is created from \fIsip_header\fR and \fIparam\fR, and is appended to
46 \fIsip_msg\fR. The \fIparam\fR can be non-null.
49 The \fBsip_copy_header_by_name()\fR function copies the header specified by
50 \fIheader_name\fR (long or short form) from \fIfrom_msg\fR to \fIto_msg\fR. The
51 new header is created using the header value from \fIfrom_msg\fR and
52 \fIparam\fR, if non-null, and appended to \fIto_msg\fR.
55 The \fBsip_copy_all_headers()\fR copies all the headers from \fIfrom_msg\fR to
60 These functions return \fB0\fR on success and the appropriate error on failure.
63 The value of \fBerrno\fR is not changed by these calls in the event of an
68 These functions can return one of the following errors in case of failure:
75 If the required input parameters are \fBNULL\fR or if the header being copied
76 does not exist or is deleted in source \fBSIP\fR message.
85 Error while allocating memory for creating the new header.
94 If the input SIP message cannot be modified.
100 See \fBattributes\fR(5) for descriptions of the following attributes:
108 ATTRIBUTE TYPE ATTRIBUTE VALUE
110 Interface Stability Committed