Commit 5f8d8161 authored by Bryan C. Mills's avatar Bryan C. Mills

cmd/go/internal/cache: verify that timestamp is positive

An apparent typo caused us to re-check size instead.

Updates #29667

Change-Id: Icc1fb9cef1ba77b8490c8fbe6c343be06ff48d8d
Reviewed-on: https://go-review.googlesource.com/c/go/+/188020
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: default avatarJay Conrod <jayconrod@google.com>
parent 2fc7574a
...@@ -173,7 +173,7 @@ func (c *Cache) get(id ActionID) (Entry, error) { ...@@ -173,7 +173,7 @@ func (c *Cache) get(id ActionID) (Entry, error) {
i++ i++
} }
tm, err := strconv.ParseInt(string(etime[i:]), 10, 64) tm, err := strconv.ParseInt(string(etime[i:]), 10, 64)
if err != nil || size < 0 { if err != nil || tm < 0 {
return missing() return missing()
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment