Skip to content

Commit

Permalink
Host: ignore empty L1 head status from enclave (#1955)
Browse files Browse the repository at this point in the history
  • Loading branch information
BedrockSquirrel committed Jun 7, 2024
1 parent f878043 commit 27bf2e3
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion go/host/enclave/state.go
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,10 @@ func (s *StateTracker) OnEnclaveStatus(es common.Status) {
s.m.Lock()
defer s.m.Unlock()
s.enclaveStatusCode = es.StatusCode
s.enclaveL1Head = es.L1Head
// only update L1 head if non-empty head reported
if es.L1Head != gethutil.EmptyHash {
s.enclaveL1Head = es.L1Head
}
s.enclaveL2Head = es.L2Head

s.setStatus(s.calculateStatus())
Expand Down

0 comments on commit 27bf2e3

Please sign in to comment.