Skip to content

Commit

Permalink
fix: crash during migration when connection is closing (#2973)
Browse files Browse the repository at this point in the history
  • Loading branch information
kostasrim committed Apr 30, 2024
1 parent fd5772a commit c84b6fa
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/facade/dragonfly_connection.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1452,7 +1452,7 @@ bool Connection::Migrate(util::fb2::ProactorBase* dest) {
CHECK(!cc_->async_dispatch);
CHECK_EQ(cc_->subscriptions, 0); // are bound to thread local caches
CHECK_EQ(self_.use_count(), 1u); // references cache our thread and backpressure
if (dispatch_fb_.IsJoinable()) { // can't move once it started
if (dispatch_fb_.IsJoinable() || cc_->conn_closing) { // can't move once it started
return false;
}

Expand Down

0 comments on commit c84b6fa

Please sign in to comment.