mirror of
https://github.com/protocolbuffers/protobuf-go.git
synced 2025-01-29 09:32:38 +00:00
4151cae27a
When loading a *MessageInfo for a legacy message type, check to see if the Go type contains at least one field which looks like a message field. Specifically, look for at least one field with a `protobuf:` tag, or an XXX_unrecognized field. If a message has no recognizable fields, assume that it's something we don't know how to interpret and treat it as an aberrant message. Change-Id: If5c09087f1a0187271c98539d761395a2ee70a9e Reviewed-on: https://go-review.googlesource.com/c/protobuf/+/210617 Reviewed-by: Joe Tsai <joetsai@google.com>