Bug 26 - Xft doesn't compute metrics correctly on non-RENDER servers
Summary: Xft doesn't compute metrics correctly on non-RENDER servers
Status: CLOSED FIXED
Alias: None
Product: xorg
Classification: Unclassified
Component: Lib/Xft (show other bugs)
Version: unspecified
Hardware: x86 (IA32) Linux (All)
: high normal
Assignee: Keith Packard
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-02-13 21:59 UTC by Nalin Dahyabhai
Modified: 2011-10-15 17:14 UTC (History)
0 users

See Also:
i915 platform:
i915 features:


Attachments
patch to clear metrics and load glyphs correctly (1.30 KB, patch)
2003-02-13 22:00 UTC, Nalin Dahyabhai
no flags Details | Splinter Review
Load missing glyphs before accessing metrics in XftGlyphFontSpecCore (1.19 KB, patch)
2003-02-14 12:24 UTC, Keith Packard
no flags Details | Splinter Review

Description Nalin Dahyabhai 2003-02-13 21:59:54 UTC
If an application calls XftGlyphExtents before attempting to draw a character,
libXft assumes that the uninitialized metrics allocated in XftFontCheckGlyph()
are valid, causing an abnormally-large XGetImage request to be generated.
Comment 1 Nalin Dahyabhai 2003-02-13 22:00:33 UTC
Created attachment 18 [details] [review]
patch to clear metrics and load glyphs correctly
Comment 2 Keith Packard 2003-02-14 12:23:13 UTC
Ah.  Your fix masks the real problem.  XftFontCheckGlyph isn't supposed to load
glyphs; it delays that to batch glyphs together in a single request.  Callers
are required to also call XftFontLoadGlyphs to actually generate
the glyph data.  I'll attach a substitute patch which should actually fix this
problem.
Comment 3 Keith Packard 2003-02-14 12:24:17 UTC
Created attachment 21 [details] [review]
Load missing glyphs before accessing metrics in XftGlyphFontSpecCore
Comment 4 Nalin Dahyabhai 2003-02-14 13:23:10 UTC
I've tested patch in attachment 21 [details] [review] locally, and it fixes the problem.
Comment 5 Mike Harris 2003-02-14 14:24:14 UTC
Confirmed, the problem appears fixed for me too.
Comment 6 Jeremy Huddleston Sequoia 2011-10-01 14:12:00 UTC
Mass update: Close all bugs resolved over one year ago.


Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.