From 13a72e15c7e92c3f8526ebf5da1aacd7413cf025 Mon Sep 17 00:00:00 2001 From: Anton Pyrogovskyi Date: Mon, 25 Oct 2021 13:57:06 +0300 Subject: [PATCH] circuit: fix version filter logic bug --- circuit/circuit.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/circuit/circuit.go b/circuit/circuit.go index 43eb990..bf6341c 100644 --- a/circuit/circuit.go +++ b/circuit/circuit.go @@ -20,8 +20,8 @@ type T []*relayentry.T // is incompatible with this wireleap. func (t T) Partition() (fronting T, entropic T, backing T) { for _, r := range t { - // exclude incompatible versions - if r.Versions.ClientRelay != nil && r.Versions.ClientRelay.Minor != clientrelay.T.Version.Minor { + // exclude older protocol & incompatible relays + if r.Versions.ClientRelay == nil || r.Versions.ClientRelay.Minor != clientrelay.T.Version.Minor { continue }