From 589b4a02bd5d183074994af1a48da6bc1b32e483 Mon Sep 17 00:00:00 2001 From: liuxiaolong <liuxiaolong@aiotlink.com> Date: 星期二, 07 九月 2021 16:14:28 +0800 Subject: [PATCH] Merge branch 'master' of http://192.168.5.22:9091/valib/c_bhomebus --- src/bus_error.cpp | 18 +++++++++++++++--- 1 files changed, 15 insertions(+), 3 deletions(-) diff --git a/src/bus_error.cpp b/src/bus_error.cpp index fe20cea..29d5683 100644 --- a/src/bus_error.cpp +++ b/src/bus_error.cpp @@ -11,13 +11,21 @@ static pthread_key_t strerrorKey; -static char *_bus_errlist[_bus_nerr] = { +static const char *_bus_errlist[_bus_nerr] = { "\0", - "Timeout", + "Timed out", "The other end is not inline", "Key already in use", "Network fault", - "Send to self error" + "Send to self error", + "Receive from wrong end", + "Service stoped", + "Exceed resource limit", + "Service not supported", + "Resource busy", + "Resource not provide", + "Invalid parameters", + "No enough memory" }; @@ -47,6 +55,10 @@ char *buf; /* Make first caller allocate key for thread-specific data */ + if (err == 0) { + err = EBUS_BASE; + } + s = pthread_once(&once, createKey); if (s != 0) err_exit(s, "pthread_once"); -- Gitblit v1.8.0