Kaydet (Commit) 603cb6cf authored tarafından Caolán McNamara's avatar Caolán McNamara

fix mem leak

Change-Id: I0d329357ac282d4652b0f7ebc401cbd51963461b
üst 5b426038
......@@ -1476,8 +1476,10 @@ static int doOpenTTFont( sal_uInt32 facenum, TrueTypeFont* t )
}
t->ntables = GetUInt16(t->ptr + tdoffset, 4);
if( t->ntables >= 128 )
if (t->ntables >= 128) {
CloseTTFont(t);
return SF_TTFORMAT;
}
t->tables = static_cast<const sal_uInt8**>(calloc(NUM_TAGS, sizeof(sal_uInt8 *)));
assert(t->tables != nullptr);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment