diff --git a/src/runtime2/connector.rs b/src/runtime2/connector.rs index 943e149661563948bd38169e4e07b8c0ddd74a11..bdda7503cfdd8efaac4edfa57a0e2365ff67c1cc 100644 --- a/src/runtime2/connector.rs +++ b/src/runtime2/connector.rs @@ -239,7 +239,7 @@ impl ConnectorPDL { // Note: we only know that a branch is waiting on a message when // it reaches the `get` call. But we might have already received // a message that targets this branch, so check now. - let mut any_branch_received = false; + let mut any_message_received = false; for message in comp_ctx.get_read_data_messages(port_id) { if self.consensus.branch_can_receive(branch_id, &message.sync_header, &message.data_header, &message.content) { // This branch can receive the message, so we do the @@ -253,11 +253,11 @@ impl ConnectorPDL { self.consensus.notify_of_received_message(receiving_branch_id, &message.sync_header, &message.data_header, &message.content); self.tree.push_into_queue(QueueKind::Runnable, receiving_branch_id); - any_branch_received = true; + any_message_received = true; } } - if any_branch_received { + if any_message_received { return ConnectorScheduling::Immediate; } } else { @@ -269,7 +269,7 @@ impl ConnectorPDL { if consistency == Consistency::Valid { branch.sync_state = SpeculativeState::ReachedSyncEnd; self.tree.push_into_queue(QueueKind::FinishedSync, branch_id); - } else if consistency == Consistency::Inconsistent { + } else { branch.sync_state = SpeculativeState::Inconsistent; } },