diff --git a/include/rpc_client.hpp b/include/rpc_client.hpp index 02bff43..557eba8 100644 --- a/include/rpc_client.hpp +++ b/include/rpc_client.hpp @@ -337,6 +337,10 @@ namespace rest_rpc { } std::unique_lock lock(write_mtx_); + if (outbox_.empty()) { + return; + } + ::free((char*)outbox_.front().first.data()); outbox_.pop_front();