Skip to content

Commit

Permalink
fix a race that occurs within server_mock used in testing
Browse files Browse the repository at this point in the history
  • Loading branch information
t-horikawa committed May 16, 2024
1 parent 0488c8f commit 2af0119
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion test/tateyama/test_utils/endpoint.h
Original file line number Diff line number Diff line change
Expand Up @@ -146,7 +146,8 @@ class endpoint {
};

endpoint(const std::string& name, const std::string& digest, boost::barrier& sync)
: name_(name), digest_(digest), container_(std::make_unique<tateyama::test_utils::connection_container>(name_, 1)), thread_(std::thread(std::ref(*this))), sync_(sync) {
: name_(name), digest_(digest), container_(std::make_unique<tateyama::test_utils::connection_container>(name_, 1)), sync_(sync) {
thread_ = std::thread(std::ref(*this));
}
~endpoint() {
if (thread_.joinable()) {
Expand Down

0 comments on commit 2af0119

Please sign in to comment.