From a99d3479a84ca86843e500dbdf58db0af389b536 Mon Sep 17 00:00:00 2001 From: Adin Scannell Date: Thu, 31 Oct 2019 18:02:04 -0700 Subject: Add context to state. PiperOrigin-RevId: 277840416 --- pkg/state/decode.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'pkg/state/decode.go') diff --git a/pkg/state/decode.go b/pkg/state/decode.go index 47e6b878a..590c241a3 100644 --- a/pkg/state/decode.go +++ b/pkg/state/decode.go @@ -16,6 +16,7 @@ package state import ( "bytes" + "context" "encoding/binary" "errors" "fmt" @@ -133,6 +134,9 @@ func (os *objectState) findCycle() []*objectState { // to ensure that all callbacks are executed, otherwise the callback graph was // not acyclic. type decodeState struct { + // ctx is the decode context. + ctx context.Context + // objectByID is the set of objects in progress. objectsByID map[uint64]*objectState -- cgit v1.2.3