1scf_error(3SCF)Service Configuration Facility Library Functionsscf_error(3SCF)
2
3
4
6 scf_error, scf_strerror - error interface to Service Configuration
7 Facility
8
10 cc [ flag... ] file... -lscf [ library... ]
11 #include <libscf.h>
12
13 scf_error_t scf_error(void);
14
15
16 const char *scf_strerror(scf_error_t error);
17
18
20 The scf_error() function returns the current libscf(3LIB) error value
21 for the current thread. If the immediately previous call to a libscf
22 function failed, the error value will reflect the reason for that fail‐
23 ure.
24
25
26 The scf_strerror() function takes an error code previously returned by
27 scf_error() and returns a human-readable, localized description of the
28 error.
29
30
31 The error values are as follows:
32
33 SCF_ERROR_BACKEND_ACCESS
34
35 The storage mechanism that the repository server (svc.configd(1M))
36 chose for the operation denied access.
37
38
39 SCF_ERROR_BACKEND_READONLY
40
41 The storage mechanism that the repository server (svc.configd)
42 chose for the operation is read-only. For the local filesystem
43 storage mechanism (currently /etc/svc/repository.db), this usually
44 occurs because the filesystem that contains it is mounted read-
45 only. See mount(1M)
46
47
48 SCF_ERROR_CONNECTION_BROKEN
49
50 The connection to repository is broken.
51
52
53 SCF_ERROR_CONSTRAINT_VIOLATED
54
55 A required constraint was not met.
56
57
58 SCF_ERROR_DELETED
59
60 Object was deleted.
61
62
63 SCF_ERROR_EXISTS
64
65 The object already exists.
66
67
68 SCF_ERROR_HANDLE_DESTROYED
69
70 An object was bound to a destroyed handle.
71
72
73 SCF_ERROR_HANDLE_MISMATCH
74
75 Objects from different SCF handles were used.
76
77
78 SCF_ERROR_IN_USE
79
80 The object is currently in use.
81
82
83 SCF_ERROR_INTERNAL
84
85 An internal error occurred.
86
87
88 SCF_ERROR_INVALID_ARGUMENT
89
90 An argument is invalid.
91
92
93 SCF_ERROR_NO_MEMORY
94
95 No memory is available.
96
97
98 SCF_ERROR_NO_RESOURCES
99
100 The repository server is out of resources.
101
102
103 SCF_ERROR_NO_SERVER
104
105 The repository server is unavailable.
106
107
108 SCF_ERROR_NONE
109
110 No error occurred.
111
112
113 SCF_ERROR_NOT_BOUND
114
115 The handle is not bound.
116
117
118 SCF_ERROR_NOT_FOUND
119
120 Nothing of that name was found.
121
122
123 SCF_ERROR_NOT_SET
124
125 Cannot use unset value.
126
127
128 SCF_ERROR_PERMISSION_DENIED
129
130 The user lacks sufficient authority to conduct the requested opera‐
131 tion. See smf_security(5).
132
133
134 SCF_ERROR_TYPE_MISMATCH
135
136 The type does not match value.
137
138
139 SCF_ERROR_VERSION_MISMATCH
140
141 The SCF version is incompatible.
142
143
145 The scf_error() function returns SCF_ERROR_NONE if there have been no
146 calls from libscf functions from the current thread. The return value
147 is undefined if the immediately previous call to a libscf function did
148 not fail.
149
151 See attributes(5) for descriptions of the following attributes:
152
153
154
155
156 ┌─────────────────────────────┬─────────────────────────────┐
157 │ ATTRIBUTE TYPE │ ATTRIBUTE VALUE │
158 ├─────────────────────────────┼─────────────────────────────┤
159 │Interface Stability │Committed │
160 ├─────────────────────────────┼─────────────────────────────┤
161 │MT-Level │MT-Safe │
162 └─────────────────────────────┴─────────────────────────────┘
163
165 svc.configd(1M), libscf(3LIB), attributes(5), svc.configd(1M)
166
167
168
169SunOS 5.11 20 Aug 2007 scf_error(3SCF)