diff options
author | Ian Jackson <Ian.Jackson@eu.citrix.com> | 2011-01-28 18:37:25 +0000 |
---|---|---|
committer | Ian Jackson <Ian.Jackson@eu.citrix.com> | 2011-01-28 18:37:25 +0000 |
commit | 91e6ad2242cf72683cf832e9c50158539a224dbf (patch) | |
tree | 70c9b281b3d7576939c8230b449cbe4c27f3cc03 /tools/libxl/libxl_internal.h | |
parent | eeec7ca8f45d82530eaac3af9d39142048844983 (diff) | |
download | xen-91e6ad2242cf72683cf832e9c50158539a224dbf.tar.gz xen-91e6ad2242cf72683cf832e9c50158539a224dbf.tar.bz2 xen-91e6ad2242cf72683cf832e9c50158539a224dbf.zip |
libxl: internals: document the error behaviour of various libxl__xs_* functions
Many of the functions in libxl_xshelp.c simply return 0 on error, and
leave the errno value from xenstore in errno. Document this more
clearly.
Also fix a >75 column line.
No functional change.
Signed-off-by: Ian Jackson <Ian.Jackson@eu.citrix.com>
Acked-by: Stefano Stabellini <stefano.stabellini@eu.citrix.com>
Committed-by: Ian Jackson <ian.jackson@eu.citrix.com>
Diffstat (limited to 'tools/libxl/libxl_internal.h')
-rw-r--r-- | tools/libxl/libxl_internal.h | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/tools/libxl/libxl_internal.h b/tools/libxl/libxl_internal.h index d58b4832bb..1e277ae5d6 100644 --- a/tools/libxl/libxl_internal.h +++ b/tools/libxl/libxl_internal.h @@ -140,13 +140,21 @@ _hidden char *libxl__strdup(libxl__gc *gc, const char *c); _hidden char *libxl__dirname(libxl__gc *gc, const char *s); _hidden char **libxl__xs_kvs_of_flexarray(libxl__gc *gc, flexarray_t *array, int length); + _hidden int libxl__xs_writev(libxl__gc *gc, xs_transaction_t t, char *dir, char **kvs); _hidden int libxl__xs_write(libxl__gc *gc, xs_transaction_t t, char *path, char *fmt, ...) PRINTF_ATTRIBUTE(4, 5); -_hidden char *libxl__xs_get_dompath(libxl__gc *gc, uint32_t domid); // logs errs + /* Each fn returns 0 on success. + * On error: returns -1, sets errno (no logging) */ + +_hidden char *libxl__xs_get_dompath(libxl__gc *gc, uint32_t domid); + /* On error: logs, returns NULL, sets errno. */ + _hidden char *libxl__xs_read(libxl__gc *gc, xs_transaction_t t, char *path); -_hidden char **libxl__xs_directory(libxl__gc *gc, xs_transaction_t t, char *path, unsigned int *nb); +_hidden char **libxl__xs_directory(libxl__gc *gc, xs_transaction_t t, + char *path, unsigned int *nb); + /* On error: returns NULL, sets errno (no logging) */ /* from xl_dom */ _hidden int libxl__domain_is_hvm(libxl_ctx *ctx, uint32_t domid); |