9075 Improve ZFS pool import/load process and corrupted pool recovery
[unleashed.git] / usr / src / man / man3sip / sip_get_header_value.3sip
blob777f1280048e33d0d1d9588c3783bd554f8c6c86
1 '\" te
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_GET_HEADER_VALUE 3SIP "Jan 25, 2007"
7 .SH NAME
8 sip_get_header_value, sip_get_next_value \- get a SIP header value
9 .SH SYNOPSIS
10 .LP
11 .nf
12 \fBcc\fR [ \fIflag\fR ... ] \fIfile\fR ... \fB-lsip\fR [ \fIlibrary\fR ... ]
13 #include <sip.h>
15 \fBconst struct sip_value *\fR\fIsip_get_header_value\fR
16      (\fBconst struct sip_header *\fR\fIsip_header\fR, \fBint *\fR\fIerror\fR);
17 .fi
19 .LP
20 .nf
21 \fBconst struct sip_value *\fR\fIsip_get_next_value\fR
22      (\fBsip_header_value_t\fR \fIold_value\fR, \fBint *\fR\fIerror\fR);
23 .fi
25 .SH DESCRIPTION
26 .sp
27 .LP
28 The \fBsip_get_header_value()\fR function returns the first valid value from
29 \fBSIP\fR header \fIsip_header\fR.
30 .sp
31 .LP
32 The \fBsip_get_next_value()\fR function returns the next valid value following
33 the \fBSIP\fR value \fIold_value\fR.
34 .SH RETURN VALUES
35 .sp
36 .LP
37 These functions return the queried value on success and \fINULL\fR on failure.
38 .sp
39 .LP
40 The value of \fBerrno\fR is not changed by these calls in the event of an
41 error.
42 .SH ERRORS
43 .sp
44 .LP
45 If the error is non-null, one of the following values is set:
46 .sp
47 .ne 2
48 .na
49 \fB\fBEINVAL\fR\fR
50 .ad
51 .RS 10n
52 If any of the required input is \fINULL\fR or if the specified \fBSIP\fR header
53 value is marked deleted.
54 .RE
56 .sp
57 .ne 2
58 .na
59 \fB\fBEPROTO\fR\fR
60 .ad
61 .RS 10n
62 If the returned \fBSIP\fR header value is invalid (i.e. the parser encountered
63 errors when parsing the value).
64 .RE
66 .sp
67 .LP
68 On success, the value of the location pointed to by \fIerror\fR is set to
69 \fB0\fR.
70 .SH ATTRIBUTES
71 .sp
72 .LP
73 See \fBattributes\fR(5) for descriptions of the following attributes:
74 .sp
76 .sp
77 .TS
78 box;
79 c | c
80 l | l .
81 ATTRIBUTE TYPE  ATTRIBUTE VALUE
83 Interface Stability     Committed
85 MT-Level        MT-Safe
86 .TE
88 .SH SEE ALSO
89 .sp
90 .LP
91 \fBlibsip\fR(3LIB)