summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKim Woelders <kim@woelders.dk>2021-09-01 19:48:18 +0200
committerKim Woelders <kim@woelders.dk>2021-09-02 19:58:04 +0200
commit397463459b4e63399a69d816a47243c0421508c4 (patch)
treef056f59010d959e13938b2aa9db3de4038844fa4
parent284a5039f9381016a6b6d0cb9b6d4eea9177159f (diff)
Fix bad memory access in draw_flame()
-rw-r--r--epplets/cloak.c2
-rw-r--r--epplets/esdcloak.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/epplets/cloak.c b/epplets/cloak.c
index b3774a9..e556fe4 100644
--- a/epplets/cloak.c
+++ b/epplets/cloak.c
@@ -254,7 +254,7 @@ draw_flame(void)
254 rgb = Epplet_get_rgb_pointer(rgbbuf); 254 rgb = Epplet_get_rgb_pointer(rgbbuf);
255 for (y = 0; y < 40; y++) 255 for (y = 0; y < 40; y++)
256 { 256 {
257 ptr = flame + (y * 40) + 1; 257 ptr = flame + (y * 40);
258 rptr = rgb + (y * 40 * 4); 258 rptr = rgb + (y * 40 * 4);
259 for (x = 0; x < 40; x++) 259 for (x = 0; x < 40; x++)
260 { 260 {
diff --git a/epplets/esdcloak.c b/epplets/esdcloak.c
index 9551b14..717cfed 100644
--- a/epplets/esdcloak.c
+++ b/epplets/esdcloak.c
@@ -291,7 +291,7 @@ draw_flame(void)
291 rgb = Epplet_get_rgb_pointer(rgbbuf); 291 rgb = Epplet_get_rgb_pointer(rgbbuf);
292 for (y = 0; y < 40; y++) 292 for (y = 0; y < 40; y++)
293 { 293 {
294 ptr = flame + (y * 40) + 1; 294 ptr = flame + (y * 40);
295 rptr = rgb + (y * 40 * 4); 295 rptr = rgb + (y * 40 * 4);
296 for (x = 0; x < 40; x++) 296 for (x = 0; x < 40; x++)
297 { 297 {