Skip to content
This repository has been archived by the owner on Dec 26, 2022. It is now read-only.

Commit

Permalink
fix(core): Move HTTP response code to status_t
Browse files Browse the repository at this point in the history
  • Loading branch information
jkrvivian committed Mar 15, 2019
1 parent 0e95a45 commit fb6c29c
Showing 1 changed file with 5 additions and 6 deletions.
11 changes: 5 additions & 6 deletions accelerator/errors.h
Original file line number Diff line number Diff line change
Expand Up @@ -47,16 +47,15 @@ extern "C" {
#define SC_ERROR_MASK 0x07
/** @} */

/** @name http error code */
/** @{ */
#define SC_BAD_REQUEST 400
#define SC_NOT_FOUND 404
/** @} */

/* status code */
typedef enum {
SC_OK = 0, /**< No error */

SC_HTTP_OK = 200, /**< HTTP response OK */
SC_BAD_REQUEST = 400, /**< HTTP response, error when parsing request */
SC_NOT_FOUND = 404, /**< HTTP request not found */
SC_INTERNAL_SERVICE_ERROR = 500, /**< HTTP response, other errors in TA */

SC_TA_OOM = 0x01 | SC_MODULE_TA | SC_SEVERITY_FATAL,
/**< Fail to create TA object */
SC_TA_NULL = 0x02 | SC_MODULE_TA | SC_SEVERITY_FATAL,
Expand Down

0 comments on commit fb6c29c

Please sign in to comment.