Fix various oversights/bugs in ZMQ RPC server code

- Add some RPC commands (and touch up a couple others)
- some bounds checking
- some better pointer management
- const correctness and error handling

-- Thanks @vtnerd for type help with serialization and CMake changes
This commit is contained in:
Thomas Winget
2017-09-05 12:20:40 -04:00
parent 77986023c3
commit 0299cb77ca
15 changed files with 536 additions and 225 deletions

View File

@@ -53,7 +53,7 @@ rapidjson::Value Message::toJson(rapidjson::Document& doc) const
val.AddMember("status", rapidjson::StringRef(status.c_str()), al);
val.AddMember("error_details", rapidjson::StringRef(error_details.c_str()), al);
INSERT_INTO_JSON_OBJECT(val, doc, rpc_version, DAEMON_RPC_VERSION);
INSERT_INTO_JSON_OBJECT(val, doc, rpc_version, DAEMON_RPC_VERSION_ZMQ);
return val;
}