Skip to content

Commit

Permalink
Fix retry counting
Browse files Browse the repository at this point in the history
  • Loading branch information
rojer committed Oct 24, 2021
1 parent bbea2a3 commit 7ad8d9d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion cli/flash/esp/flasher/flasher_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -406,7 +406,7 @@ func (fc *FlasherClient) Read(addr uint32, data []byte) error {
}
if err != nil {
err = errors.Annotatef(err, "flash read failed @ 0x%x (try %d of %d)", numRead, attempt, flashReadAttempts)
if attempt > flashReadAttempts {
if attempt >= flashReadAttempts {
return err
}
glog.Warningf("%v", err)
Expand Down

0 comments on commit 7ad8d9d

Please sign in to comment.