[webkit-reviews] review requested: [Bug 19542] Crash in Font::glyphDataForCharacter when getting small caps data : [Attachment 21842] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Jun 19 11:01:05 PDT 2008

Marvin Decker <marv.decker at gmail.com> has asked  for review:
Bug 19542: Crash in Font::glyphDataForCharacter when getting small caps data

Attachment 21842: Patch

------- Additional Comments from Marvin Decker <marv.decker at gmail.com>
This patch just adds a NULL check for the page() of glyphs like the rest of the
file. If this fails, it does the same thing it would do if the GlyphData in the
page is NULL.

I did not add a test. This patch is based on a crash report I saw. The stack is
clear that the crash is dereferencing a NULL from the page() here, but I can
not reproduce, even opening the page that triggered the crash report. I also
tried to generate some small caps text in a funny language that wouldn't be in
the font, but I could not trigger it. It is probably highly dependent on the
WebKit port, OS, and installed fonts. If you have an idea for a test, I'll be
happy to write it.

More information about the webkit-reviews mailing list