aboutsummaryrefslogtreecommitdiffstats
path: root/src/synchronizer.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/synchronizer.rs')
-rw-r--r--src/synchronizer.rs5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/synchronizer.rs b/src/synchronizer.rs
index 277bf64..cfc4cd3 100644
--- a/src/synchronizer.rs
+++ b/src/synchronizer.rs
@@ -136,14 +136,15 @@ impl Synchronizer {
}
fn handle_msg(&mut self, pm: &PeerMsg) -> Result<()> {
+ // NB: this is the simplistic model of registers (only works up to 2x per peer)
// mutable ref to PeerThread for this message
let pt = self.peers.get_mut(&pm.peer_handle).unwrap();
// NB: this is the simplistic model of registers (only works up to 2x per peer?)
if pm.feed_index as usize >= self.registers.len() {
- // XXX: invalid feed! drop connection
- pt.close()?;
+ // Ignore feed channels we haven't registered yet
+ return Ok(());
}
match &pm.msg {