Bug 1391855 - OTS: Match signedness in GlatEntry loop. r?jfkthame draft 7-1391855
authorKevin Hsieh <kevin.hsieh@ucla.edu>
Sat, 19 Aug 2017 15:26:11 -0700
branch7-1391855
changeset 649516 258de90aa1e4008eec5076ab795f0942163aebb3
parent 649312 4f4487cc2d30d988742109868dcf21c4113f12f5
child 727092 4357e4ec724e6ebe680a4bf2b58f06f8680c5dc0
push id75047
push userbmo:kevin.hsieh@ucla.edu
push dateSat, 19 Aug 2017 22:29:11 +0000
reviewersjfkthame
bugs1391855
milestone57.0a1
Bug 1391855 - OTS: Match signedness in GlatEntry loop. r?jfkthame MozReview-Commit-ID: IzzWbNVEwh
gfx/ots/README.mozilla
gfx/ots/src/glat.cc
--- a/gfx/ots/README.mozilla
+++ b/gfx/ots/README.mozilla
@@ -1,12 +1,12 @@
 This is the Sanitiser for OpenType project, from http://code.google.com/p/ots/.
 
 Our reference repository is https://github.com/khaledhosny/ots/.
 
-Current revision: 57ef618b11aa0409637af04988ccce7e6b92ed0f (5.2.0)
+Current revision: e2d4b5daba24e746a48d240e90d92fe09a20b681 (5.2.0)
 
 Upstream files included: LICENSE, src/, include/, tests/*.cc
 
 Additional files: README.mozilla, src/moz.build
 
 Additional patch: ots-visibility.patch (bug 711079).
 Additional patch: ots-lz4.patch
--- a/gfx/ots/src/glat.cc
+++ b/gfx/ots/src/glat.cc
@@ -69,17 +69,17 @@ bool OpenTypeGLAT_v1::GlatEntry::ParsePa
   if (!table.ReadU8(&this->attNum)) {
     return parent->Error("GlatEntry: Failed to read attNum");
   }
   if (!table.ReadU8(&this->num)) {
     return parent->Error("GlatEntry: Failed to read num");
   }
 
   //this->attributes.resize(this->num);
-  for (unsigned i = 0; i < this->num; ++i) {
+  for (int i = 0; i < this->num; ++i) {
     this->attributes.emplace_back();
     if (!table.ReadS16(&this->attributes[i])) {
       return parent->Error("GlatEntry: Failed to read attribute %u", i);
     }
   }
   return true;
 }
 
@@ -151,17 +151,17 @@ bool OpenTypeGLAT_v2::GlatEntry::ParsePa
   if (!table.ReadS16(&this->attNum)) {
     return parent->Error("GlatEntry: Failed to read attNum");
   }
   if (!table.ReadS16(&this->num) || this->num < 0) {
     return parent->Error("GlatEntry: Failed to read valid num");
   }
 
   //this->attributes.resize(this->num);
-  for (unsigned i = 0; i < this->num; ++i) {
+  for (int i = 0; i < this->num; ++i) {
     this->attributes.emplace_back();
     if (!table.ReadS16(&this->attributes[i])) {
       return parent->Error("GlatEntry: Failed to read attribute %u", i);
     }
   }
   return true;
 }