summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndrew Mahone <andrew.mahone@gmail.com>2009-01-29 03:30:33 +0000
committerAndrew Mahone <andrew.mahone@gmail.com>2009-01-29 03:30:33 +0000
commit83350f2fed074058f3f90095c2711196941c2eab (patch)
tree3ac706b28436858c87e1227f20843b02ebb82156
parent34b3fd9f619b35f2583ca2ac97ee3d73cbe2b9ba (diff)
downloadrockbox-83350f2fed074058f3f90095c2711196941c2eab.tar.gz
rockbox-83350f2fed074058f3f90095c2711196941c2eab.zip
fix divide-by-zero error in pictureflow when selecting album
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@19876 a1c6a512-1295-4272-9138-f99709370657
-rw-r--r--apps/plugins/pictureflow.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/apps/plugins/pictureflow.c b/apps/plugins/pictureflow.c
index ca1f0715b3..2dbbb81d85 100644
--- a/apps/plugins/pictureflow.c
+++ b/apps/plugins/pictureflow.c
@@ -1180,8 +1180,8 @@ void render_slide(struct slide_data *slide, const int alpha)
int distance = (h + slide->distance) * 100 / zoom;
- PFreal dist = distance * PFREAL_ONE;
if (distance < 100 ) distance = 100; /* clamp distances */
+ PFreal dist = distance * PFREAL_ONE;
PFreal sdx = fcos(slide->angle);
PFreal sdy = fsin(slide->angle);
PFreal xs = slide->cx - sw * fdiv(sdx, dist) / 2;