Merge pull request #257 from haberman/warnings2

Fixed narrowing warnings in text_encode.c.
pull/13171/head
Joshua Haberman 5 years ago committed by GitHub
commit a3d693544b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      upb/text_encode.c

@ -260,7 +260,7 @@ static const char *txtenc_unknown(txtenc *e, const char *ptr, const char *end,
uint32_t tag; uint32_t tag;
CHK(ptr = txtenc_parsevarint(ptr, end, &tag_64)); CHK(ptr = txtenc_parsevarint(ptr, end, &tag_64));
CHK(tag_64 < UINT32_MAX); CHK(tag_64 < UINT32_MAX);
tag = tag_64; tag = (uint32_t)tag_64;
if ((tag & 7) == UPB_WIRE_TYPE_END_GROUP) { if ((tag & 7) == UPB_WIRE_TYPE_END_GROUP) {
CHK((tag >> 3) == groupnum); CHK((tag >> 3) == groupnum);

Loading…
Cancel
Save