From b6f61b34b5ab96fd86e8bd4a5b63bb2f8f9d95ed Mon Sep 17 00:00:00 2001 From: Andreas Schneider Date: Thu, 7 Apr 2011 15:27:26 +0200 Subject: [PATCH] libsmbconf: Introduce a sbcErrType. Signed-off-by: Michael Adam (cherry picked from commit 193a07af54184a257ada9401613e1de2e62d60d1) --- lib/smbconf/smbconf.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/lib/smbconf/smbconf.h b/lib/smbconf/smbconf.h index 517302ac883..dc640d075b6 100644 --- a/lib/smbconf/smbconf.h +++ b/lib/smbconf/smbconf.h @@ -20,6 +20,29 @@ #ifndef __LIBSMBCONF_H__ #define __LIBSMBCONF_H__ +/** + * @brief Status codes returned from smbconf functions + */ +enum _sbcErrType { + SBC_ERR_OK = 0, /**< Successful completion **/ + SBC_ERR_NOT_IMPLEMENTED, /**< Function not implemented **/ + SBC_ERR_NOT_SUPPORTED, /**< Function not supported **/ + SBC_ERR_UNKNOWN_FAILURE, /**< General failure **/ + SBC_ERR_NOMEM, /**< Memory allocation error **/ + SBC_ERR_INVALID_PARAM, /**< An Invalid parameter was supplied **/ + SBC_ERR_BADFILE, /**< A bad file was supplied **/ + SBC_ERR_NO_SUCH_SERVICE, /**< There is no such service provided **/ + SBC_ERR_IO_FAILURE, /**< There was an IO error **/ + SBC_ERR_CAN_NOT_COMPLETE,/**< Can not complete action **/ + SBC_ERR_NO_MORE_ITEMS, /**< No more items left **/ + SBC_ERR_FILE_EXISTS, /**< File already exists **/ + SBC_ERR_ACCESS_DENIED, /**< Access has been denied **/ +}; + +typedef enum _sbcErrType sbcErr; + +#define SBC_ERROR_IS_OK(x) ((x) == SBC_ERR_OK) + struct smbconf_ctx; /* the change sequence number */ -- 2.11.4.GIT