Mirror of https://github.com/cue-lang/cue cuelang.org
cue go

protobuf/jsonpb: fix panic when decoding non-string bytes master

``` exec cue eval schema.cue json+pb: data.json -- schema.cue -- t: bytes @protobuf(1, bytes) -- data.json -- {"t": 42} ``` This would panic because of a logic error in jsonpb/decoder.go Signed-off-by: Matthew Sackman <matthew@cue.works> Change-Id: Ie9c0bf1670a01f3223fb85d354a36ff1dfacedda Reviewed-on: https://cue.gerrithub.io/c/cue-lang/cue/+/1234625 TryBot-Result: CUEcueckoo <cueckoo@cuelang.org> Unity-Result: CUE porcuepine <cue.porcuepine@gmail.com> Reviewed-by: Roger Peppe <rogpeppe@gmail.com>


+7 -1
2 changed files