diff --git a/include/caosdb/status_code.h b/include/caosdb/status_code.h index 246a7c89d7e79937d4446416e5e2fb3736061b1c..3a49d9513dc722c0cd49f7f3d6891e282dda423c 100644 --- a/include/caosdb/status_code.h +++ b/include/caosdb/status_code.h @@ -53,6 +53,7 @@ enum StatusCode { UNSUPPORTED_FEATURE = 27, ORIGINAL_ENTITY_MISSING_ID = 28, EXTERN_C_ASSIGNMENT_ERROR = 29, + OTHER_CLIENT_ERROR = 9999; }; auto get_status_description(int code) -> const std::string &; diff --git a/src/caosdb/transaction.cpp b/src/caosdb/transaction.cpp index 0a7cedd8d81b37b6b6e318474edab2fed500b8a4..a7ddba88dc32543a0daf63ad5b4c199b56d2b919 100644 --- a/src/caosdb/transaction.cpp +++ b/src/caosdb/transaction.cpp @@ -83,7 +83,11 @@ auto get_status_description(int code) -> const std::string & { "This feature is not available in the this client implementation."}, {StatusCode::EXTERN_C_ASSIGNMENT_ERROR, "You tried to assign a new object to the wrapped void pointer. You have " - "to delete the old pointee first."}}; + "to delete the old pointee first."}, + {StatusCode::OTHER_CLIENT_ERROR, + "This is code is reserved to errors raised by other clients wrapping the " + "C++ client (or its Extern C interface). This should never occur when " + "working with the C++ code itself."}}; try { return descriptions.at(code); } catch (const std::out_of_range &exc) {