diff options
Diffstat (limited to 'src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp')
-rw-r--r-- | src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp b/src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp index 928baca6..9d9de53a 100644 --- a/src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp +++ b/src/rpc-server/trex_rpc_jsonrpc_v2_parser.cpp @@ -225,3 +225,11 @@ std::string TrexJsonRpcV2Parser::pretty_json_str(const std::string &json_str) { return writer.write(value); } +void +TrexJsonRpcV2Parser::generate_common_error(Json::Value &json, const std::string &specific_err) { + JsonRpcError err(Json::Value::null, JSONRPC_V2_ERR_INTERNAL_ERROR, specific_err, true); + + err.execute(json); + +} + |