From 9a787951b1a05dd1487907e13ec92fac3657f363 Mon Sep 17 00:00:00 2001 From: xdrm-brackets Date: Sat, 21 Apr 2018 19:46:37 +0200 Subject: [PATCH] [client.keyset] removed 'max' that is now in 'ctx' --- src/git.xdrm.io/schastsp/client/keyset/keyset.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/git.xdrm.io/schastsp/client/keyset/keyset.go b/src/git.xdrm.io/schastsp/client/keyset/keyset.go index 6740e53..913d94c 100644 --- a/src/git.xdrm.io/schastsp/client/keyset/keyset.go +++ b/src/git.xdrm.io/schastsp/client/keyset/keyset.go @@ -16,7 +16,6 @@ const SecretSize = scha.HSIZE * 4; type T struct { ctx *context.T // current context depth uint16 // cur depth - max uint16 // max depth sec []byte // secret consumed bool // if secret is consumed @@ -125,7 +124,7 @@ func (s *T) Decrement() uint16 { s.consumed = s.depth <= s.ctx.MinDepth()+s.ctx.DepthThreshold() /* (3) Return remaining attempts */ - return s.depth - s.max + return s.depth - s.ctx.MaxDepth() }