aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/libcharon/plugins/vici/libvici.h19
1 files changed, 17 insertions, 2 deletions
diff --git a/src/libcharon/plugins/vici/libvici.h b/src/libcharon/plugins/vici/libvici.h
index 2689b39e1..04d8f4a8e 100644
--- a/src/libcharon/plugins/vici/libvici.h
+++ b/src/libcharon/plugins/vici/libvici.h
@@ -28,8 +28,8 @@
* - vici_connect(): Connect to a vici service
* - vici_disconnect(): Disconnect from a vici service
*
- * Library initialization is basically required to set up libstrongswan and
- * a small thread pool. Initialize libstrongswan manually instead.
+ * Library initialization implicitly initializes libstrongswan and a small
+ * thread pool.
*
* Connecting requires an uri, which is currently either a UNIX socket path
* prefixed with unix://, or a hostname:port touple prefixed with tcp://.
@@ -269,6 +269,8 @@ void vici_free_req(vici_req_t *req);
/**
* Dump a message text representation to a FILE stream.
*
+ * On error, errno is set appropriately.
+ *
* @param res response message to dump
* @param label a label to print for this message
* @param out FILE to dump to
@@ -292,6 +294,8 @@ vici_parse_t vici_parse(vici_res_t *res);
*
* The string is valid until vici_free_res() is called.
*
+ * On error, errno is set appropriately.
+ *
* @param res response message to parse
* @return name tag / key, NULL on error
*/
@@ -314,7 +318,13 @@ int vici_parse_name_eq(vici_res_t *res, char *name);
*
* This call is valid only after vici_parse() returned VICI_PARSE_KEY_VALUE or
* VICI_PARSE_LIST_ITEM.
+ *
* The string is valid until vici_free_res() is called.
+ *
+ * On error, errno is set appropriately.
+ *
+ * @param len pointer receiving value length
+ * @return pointer to value, NULL on error
*/
void* vici_parse_value(vici_res_t *res, int *len);
@@ -323,9 +333,12 @@ void* vici_parse_value(vici_res_t *res, int *len);
*
* This call is valid only after vici_parse() returned VICI_PARSE_KEY_VALUE or
* VICI_PARSE_LIST_ITEM.
+ *
* This call is successful only if the value contains no non-printable
* characters. The string is valid until vici_free_res() is called.
*
+ * On error, errno is set appropriately.
+ *
* @param res response message to parse
* @return value as string, NULL on error
*/
@@ -338,6 +351,8 @@ char* vici_parse_value_str(vici_res_t *res);
* invoked for the current section level only. To descent into sections, call
* vici_parse_cb() from within a section callback.
*
+ * On error, errno is set appropriately.
+ *
* @param res message to parse
* @param section callback invoked for each section
* @param kv callback invoked for key/value pairs