forked from len0rd/rockbox
Fix for unlikely, but possible, division-by-zero
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@13385 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
parent
9a90d557e4
commit
21d538b98e
1 changed files with 6 additions and 3 deletions
|
|
@ -323,9 +323,12 @@ static bool dbg_audio_thread(void)
|
||||||
lcd_puts(0, line++, buf);
|
lcd_puts(0, line++, buf);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
snprintf(buf, sizeof(buf), "boost ratio: %3d%%",
|
if (ticks > 0)
|
||||||
boost_ticks * 100 / ticks);
|
{
|
||||||
lcd_puts(0, line++, buf);
|
snprintf(buf, sizeof(buf), "boost ratio: %3d%%",
|
||||||
|
boost_ticks * 100 / ticks);
|
||||||
|
lcd_puts(0, line++, buf);
|
||||||
|
}
|
||||||
|
|
||||||
snprintf(buf, sizeof(buf), "pcmbufdesc: %2d/%2d",
|
snprintf(buf, sizeof(buf), "pcmbufdesc: %2d/%2d",
|
||||||
pcmbuf_used_descs(), pcmbufdescs);
|
pcmbuf_used_descs(), pcmbufdescs);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue