summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStijn Tintel <stijn@linux-ipv6.be>2022-02-18 18:13:56 +0200
committerStijn Tintel <stijn@linux-ipv6.be>2022-02-28 16:07:18 +0200
commit66baa44b8deea962d5cbf2f77736075eb78769f6 (patch)
treea2bf847dad3d065ba2514a4e4cc63b3a14106f48
parenta72457b61df045d3c499a6211362b751710590d7 (diff)
downloadubus-66baa44b8deea962d5cbf2f77736075eb78769f6.tar.gz
libubus: introduce new status messages
Introduce the following new status messages in libubus: UBUS_STATUS_NO_MEMORY UBUS_STATUS_PARSE_ERROR UBUS_STATUS_SYSTEM_ERROR Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Petr Štetiar <ynezz@true.cz> Acked-by: Jo-Philipp Wich <jo@mein.io>
-rw-r--r--libubus.c3
-rw-r--r--ubusmsg.h3
2 files changed, 6 insertions, 0 deletions
diff --git a/libubus.c b/libubus.c
index aee2a3b..fc0d933 100644
--- a/libubus.c
+++ b/libubus.c
@@ -34,6 +34,9 @@ const char *__ubus_strerror[__UBUS_STATUS_LAST] = {
[UBUS_STATUS_NOT_SUPPORTED] = "Operation not supported",
[UBUS_STATUS_UNKNOWN_ERROR] = "Unknown error",
[UBUS_STATUS_CONNECTION_FAILED] = "Connection failed",
+ [UBUS_STATUS_NO_MEMORY] = "Out of memory",
+ [UBUS_STATUS_PARSE_ERROR] = "Parsing message data failed",
+ [UBUS_STATUS_SYSTEM_ERROR] = "System error",
};
struct blob_buf b __hidden = {};
diff --git a/ubusmsg.h b/ubusmsg.h
index 398b126..b2df8dc 100644
--- a/ubusmsg.h
+++ b/ubusmsg.h
@@ -127,6 +127,9 @@ enum ubus_msg_status {
UBUS_STATUS_NOT_SUPPORTED,
UBUS_STATUS_UNKNOWN_ERROR,
UBUS_STATUS_CONNECTION_FAILED,
+ UBUS_STATUS_NO_MEMORY,
+ UBUS_STATUS_PARSE_ERROR,
+ UBUS_STATUS_SYSTEM_ERROR,
__UBUS_STATUS_LAST
};