diff options
author | Daniel Stenberg <daniel@haxx.se> | 2002-06-24 06:55:20 +0000 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2002-06-24 06:55:20 +0000 |
commit | 94f0b55c645564a60277015e9ba790a1b95a4637 (patch) | |
tree | 802fd1938809317f36eddbd6c37b6e403bccf7bd /firmware/drivers/lcd.c | |
parent | 848c2cd7338490b2237b0ef86528f2bea2020f47 (diff) | |
download | rockbox-94f0b55c645564a60277015e9ba790a1b95a4637.tar.gz rockbox-94f0b55c645564a60277015e9ba790a1b95a4637.zip |
the scroll loop could end up scrolling forever!
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@1135 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'firmware/drivers/lcd.c')
-rw-r--r-- | firmware/drivers/lcd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/firmware/drivers/lcd.c b/firmware/drivers/lcd.c index e77fd56b56..be71c25311 100644 --- a/firmware/drivers/lcd.c +++ b/firmware/drivers/lcd.c | |||
@@ -933,7 +933,9 @@ void lcd_puts_scroll(int x, int y, char* string ) | |||
933 | ch[0] = string[0]; | 933 | ch[0] = string[0]; |
934 | width = 0; | 934 | width = 0; |
935 | for (s->space = 0; | 935 | for (s->space = 0; |
936 | width + lcd_getstringsize(ch, 0, &w, &h) < (LCD_WIDTH - x*8); ) { | 936 | string[(int)s->space] && |
937 | (width + lcd_getstringsize(ch, 0, &w, &h) < (LCD_WIDTH - x*8)); | ||
938 | ) { | ||
937 | width += lcd_getstringsize(ch, 0, &w, &h); | 939 | width += lcd_getstringsize(ch, 0, &w, &h); |
938 | ch[0]=string[(int)++s->space]; | 940 | ch[0]=string[(int)++s->space]; |
939 | } | 941 | } |