Merge "entry_name_utils-inl.h: clear top bit before shifting" am: a72477630d

am: a5ff3e1276

Change-Id: I1cd6b19a88c425aa16019b406454e7aaad4a16af
This commit is contained in:
Nick Kralevich 2019-03-22 20:21:46 -07:00 committed by android-build-merger
commit 15d1c2ec65

View file

@ -35,7 +35,7 @@ inline bool IsValidEntryName(const uint8_t* entry_name, const size_t length) {
return false;
} else {
// 2-5 byte sequences.
for (uint8_t first = byte << 1; first & 0x80; first <<= 1) {
for (uint8_t first = (byte & 0x7f) << 1; first & 0x80; first = (first & 0x7f) << 1) {
++i;
// Missing continuation byte..