X-Git-Url: https://codewiz.org/gitweb?a=blobdiff_plain;f=gfx%2Ftext_format.c;h=1b0e8a340571b976f160a7466807a7bb2ea1d500;hb=0c154bc0927a32f77467f32aac3cc3507baa97ca;hp=e1452d8a0015f0f354d1f40c4b9c1b0e7b236ca9;hpb=c66da8dee53d20f2bc02267d798530f5fb1bf37f;p=bertos.git diff --git a/gfx/text_format.c b/gfx/text_format.c index e1452d8a..1b0e8a34 100755 --- a/gfx/text_format.c +++ b/gfx/text_format.c @@ -15,6 +15,9 @@ /*#* *#* $Log$ + *#* Revision 1.6 2006/03/13 02:05:54 bernie + *#* Mark slow paths as UNLIKELY. + *#* *#* Revision 1.5 2006/03/07 22:18:04 bernie *#* Correctly compute text width for prop fonts; Make styles a per-bitmap attribute. *#* @@ -219,7 +222,7 @@ static int text_charWidth(int c, struct TextWidthData *twd) coord_t glyph_width; - if (index < bm->font->first || index > bm->font->last) + if (UNLIKELY(index < bm->font->first || index > bm->font->last)) { if ('?' >= bm->font->first && '?' <= bm->font->last) index = '?';