Commit 5d328282 authored by Albert Astals Cid's avatar Albert Astals Cid

bitmap->h can be 0, move to _checkoverflow variant, code already knows how to deal with NULL

parent 5b0fb6f9
...@@ -243,7 +243,7 @@ GBool SplashFTFont::makeGlyph(int c, int xFrac, int yFrac, ...@@ -243,7 +243,7 @@ GBool SplashFTFont::makeGlyph(int c, int xFrac, int yFrac,
} else { } else {
rowSize = (bitmap->w + 7) >> 3; rowSize = (bitmap->w + 7) >> 3;
} }
bitmap->data = (Guchar *)gmallocn(rowSize, bitmap->h); bitmap->data = (Guchar *)gmallocn_checkoverflow(rowSize, bitmap->h);
bitmap->freeData = gTrue; bitmap->freeData = gTrue;
for (i = 0, p = bitmap->data, q = slot->bitmap.buffer; for (i = 0, p = bitmap->data, q = slot->bitmap.buffer;
i < bitmap->h; i < bitmap->h;
......
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