summaryrefslogtreecommitdiff
path: root/firmware
diff options
context:
space:
mode:
authorFred Bauer <fred.w.bauer@gmail.com>2010-08-27 15:10:30 +0000
committerFred Bauer <fred.w.bauer@gmail.com>2010-08-27 15:10:30 +0000
commitedb28753b07a927a9f797c99ec97061499c67d84 (patch)
treef816c101f65276283aad890e8afd77ff4fe3727d /firmware
parent9067fe30313412dfa454bfeac64f409d0d1b96e5 (diff)
downloadrockbox-edb28753b07a927a9f797c99ec97061499c67d84.tar.gz
rockbox-edb28753b07a927a9f797c99ec97061499c67d84.zip
limit font_cache preloading to cache capacity
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@27909 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware')
-rw-r--r--firmware/font.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/firmware/font.c b/firmware/font.c
index 98bd6399fe..77cf66c737 100644
--- a/firmware/font.c
+++ b/firmware/font.c
@@ -723,7 +723,7 @@ static void glyph_cache_load(struct font* pf)
723 close(fd); 723 close(fd);
724 } else { 724 } else {
725 /* load latin1 chars into cache */ 725 /* load latin1 chars into cache */
726 for ( ch = 32 ; ch < 256 ; ch++ ); 726 for ( ch = 32 ; ch < 256 && ch < pf->cache._capacity + 32; ch++ )
727 font_get_bits(pf, ch); 727 font_get_bits(pf, ch);
728 } 728 }
729 } 729 }