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

Commit fb6c29c

Browse files
committed
fix(core): Move HTTP response code to status_t
1 parent 0e95a45 commit fb6c29c

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

accelerator/errors.h

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,16 +47,15 @@ extern "C" {
4747
#define SC_ERROR_MASK 0x07
4848
/** @} */
4949

50-
/** @name http error code */
51-
/** @{ */
52-
#define SC_BAD_REQUEST 400
53-
#define SC_NOT_FOUND 404
54-
/** @} */
55-
5650
/* status code */
5751
typedef enum {
5852
SC_OK = 0, /**< No error */
5953

54+
SC_HTTP_OK = 200, /**< HTTP response OK */
55+
SC_BAD_REQUEST = 400, /**< HTTP response, error when parsing request */
56+
SC_NOT_FOUND = 404, /**< HTTP request not found */
57+
SC_INTERNAL_SERVICE_ERROR = 500, /**< HTTP response, other errors in TA */
58+
6059
SC_TA_OOM = 0x01 | SC_MODULE_TA | SC_SEVERITY_FATAL,
6160
/**< Fail to create TA object */
6261
SC_TA_NULL = 0x02 | SC_MODULE_TA | SC_SEVERITY_FATAL,

0 commit comments

Comments
 (0)