Change information
Commit message:
internal/impl: fix size cache semantics with lazy decoding
When a message (within an extension) is lazily decoded, its size cache is
initialized to 0 (the zero value for an int32). This doesn’t mean the size cache
reads 0, but rather that it was not initialized.
This fixes TestExtensionGetRace being flaky since CL 580015.
related to golang/protobuf#1609
Change-Id: Ia305badadd300679975f230005c3e33c94050e4a
Files:
- M internal/impl/encode.go
Change size: S
Delta: 1 file changed, 12 insertions(+), 6 deletions(-)
Branch: refs/heads/master
Submit Requirements:
Code-Review: +2 by Lasse Folger
TryBots-Pass: LUCI-TryBot-Result+1 by Go LUCI