add unlikely to error handling

This commit is contained in:
Michiharu Ariza 2018-12-04 10:39:17 -08:00
parent b61f74f69a
commit 6ce8d10b45
2 changed files with 2 additions and 2 deletions

View File

@ -1093,7 +1093,7 @@ struct cff1
CFF1FontDict_Interpreter font_interp;
font_interp.env.init (fontDictStr);
font = fontDicts.push ();
if (font == &Crap(CFF1FontDictValues)) { fini (); return; }
if (unlikely (font == &Crap(CFF1FontDictValues))) { fini (); return; }
font->init ();
if (unlikely (!font_interp.interpret (*font))) { fini (); return; }
PRIVDICTVAL *priv = &privateDicts[i];

View File

@ -486,7 +486,7 @@ struct cff2
CFF2FontDict_Interpreter font_interp;
font_interp.env.init (fontDictStr);
font = fontDicts.push ();
if (font == &Crap(CFF2FontDictValues)) { fini (); return; }
if (unlikely (font == &Crap(CFF2FontDictValues))) { fini (); return; }
font->init ();
if (unlikely (!font_interp.interpret (*font))) { fini (); return; }