Loading include/norns/norns.h +5 −4 Original line number Diff line number Diff line Loading @@ -32,9 +32,9 @@ #define NORNS_API_VERSION 10 #endif #include <sys/types.h> #include <stdint.h> #include <assert.h> #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> /* For bool */ #include <time.h> /* For struct timespec */ #include "norns_types.h" #include "norns_error.h" Loading Loading @@ -68,7 +68,8 @@ norns_submit(norns_iotask_t* task) __THROW; /* wait for the completion of the I/O task associated to 'task' */ norns_error_t norns_wait(norns_iotask_t* task) __THROW; norns_wait(norns_iotask_t* task, const struct timespec* timeout) __THROW; /* Try to cancel an asynchronous I/O task associated with task */ norns_error_t Loading include/norns/norns_error.h +5 −4 Original line number Diff line number Diff line Loading @@ -45,12 +45,13 @@ extern "C" { #define NORNS_EBADARGS -2 #define NORNS_EBADREQUEST -3 #define NORNS_ENOMEM -4 #define NORNS_ETIMEOUT -5 /* errors about communication */ #define NORNS_ECONNFAILED -5 #define NORNS_ERPCSENDFAILED -6 #define NORNS_ERPCRECVFAILED -7 #define NORNS_EACCEPTPAUSED -8 #define NORNS_ECONNFAILED -6 #define NORNS_ERPCSENDFAILED -7 #define NORNS_ERPCRECVFAILED -8 #define NORNS_EACCEPTPAUSED -9 /* errors about jobs */ #define NORNS_EJOBEXISTS -10 Loading include/norns/norns_types.h +0 −2 Original line number Diff line number Diff line Loading @@ -29,8 +29,6 @@ #define __NORNS_TYPES_H__ 1 #include <sys/types.h> #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> #ifdef __cplusplus extern "C" { Loading include/norns/nornsctl.h +6 −1 Original line number Diff line number Diff line Loading @@ -32,6 +32,10 @@ #define NORNSCTL_API_VERSION 10 #endif #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> /* For bool */ #include <time.h> /* For struct timespec */ #include "norns_types.h" #include "norns_error.h" Loading Loading @@ -191,7 +195,8 @@ nornsctl_submit(norns_iotask_t* task) __THROW; /* wait for the completion of the I/O task associated to 'task' */ norns_error_t nornsctl_wait(norns_iotask_t* task) __THROW; nornsctl_wait(norns_iotask_t* task, const struct timespec* timeout) __THROW; /* Try to cancel an asynchronous I/O task associated with task */ norns_error_t Loading lib/errors.c +1 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,7 @@ const char* const norns_errlist[NORNS_ERRMAX + 1] = { [ERR_REMAP(NORNS_EBADREQUEST)] = "Bad request", [ERR_REMAP(NORNS_EBADARGS)] = "Bad arguments", [ERR_REMAP(NORNS_ENOMEM)] = "Cannot allocate memory", [ERR_REMAP(NORNS_ETIMEOUT)] = "Timeout exceeded", /* communication errors */ [ERR_REMAP(NORNS_ECONNFAILED)] = "Cannot connect to daemon", Loading Loading
include/norns/norns.h +5 −4 Original line number Diff line number Diff line Loading @@ -32,9 +32,9 @@ #define NORNS_API_VERSION 10 #endif #include <sys/types.h> #include <stdint.h> #include <assert.h> #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> /* For bool */ #include <time.h> /* For struct timespec */ #include "norns_types.h" #include "norns_error.h" Loading Loading @@ -68,7 +68,8 @@ norns_submit(norns_iotask_t* task) __THROW; /* wait for the completion of the I/O task associated to 'task' */ norns_error_t norns_wait(norns_iotask_t* task) __THROW; norns_wait(norns_iotask_t* task, const struct timespec* timeout) __THROW; /* Try to cancel an asynchronous I/O task associated with task */ norns_error_t Loading
include/norns/norns_error.h +5 −4 Original line number Diff line number Diff line Loading @@ -45,12 +45,13 @@ extern "C" { #define NORNS_EBADARGS -2 #define NORNS_EBADREQUEST -3 #define NORNS_ENOMEM -4 #define NORNS_ETIMEOUT -5 /* errors about communication */ #define NORNS_ECONNFAILED -5 #define NORNS_ERPCSENDFAILED -6 #define NORNS_ERPCRECVFAILED -7 #define NORNS_EACCEPTPAUSED -8 #define NORNS_ECONNFAILED -6 #define NORNS_ERPCSENDFAILED -7 #define NORNS_ERPCRECVFAILED -8 #define NORNS_EACCEPTPAUSED -9 /* errors about jobs */ #define NORNS_EJOBEXISTS -10 Loading
include/norns/norns_types.h +0 −2 Original line number Diff line number Diff line Loading @@ -29,8 +29,6 @@ #define __NORNS_TYPES_H__ 1 #include <sys/types.h> #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> #ifdef __cplusplus extern "C" { Loading
include/norns/nornsctl.h +6 −1 Original line number Diff line number Diff line Loading @@ -32,6 +32,10 @@ #define NORNSCTL_API_VERSION 10 #endif #include <stdint.h> /* For uint32_t et al. */ #include <stdbool.h> /* For bool */ #include <time.h> /* For struct timespec */ #include "norns_types.h" #include "norns_error.h" Loading Loading @@ -191,7 +195,8 @@ nornsctl_submit(norns_iotask_t* task) __THROW; /* wait for the completion of the I/O task associated to 'task' */ norns_error_t nornsctl_wait(norns_iotask_t* task) __THROW; nornsctl_wait(norns_iotask_t* task, const struct timespec* timeout) __THROW; /* Try to cancel an asynchronous I/O task associated with task */ norns_error_t Loading
lib/errors.c +1 −0 Original line number Diff line number Diff line Loading @@ -35,6 +35,7 @@ const char* const norns_errlist[NORNS_ERRMAX + 1] = { [ERR_REMAP(NORNS_EBADREQUEST)] = "Bad request", [ERR_REMAP(NORNS_EBADARGS)] = "Bad arguments", [ERR_REMAP(NORNS_ENOMEM)] = "Cannot allocate memory", [ERR_REMAP(NORNS_ETIMEOUT)] = "Timeout exceeded", /* communication errors */ [ERR_REMAP(NORNS_ECONNFAILED)] = "Cannot connect to daemon", Loading