From: | "Michael Sterrett (mr_bones_)" <mr_bones_@g.o> |
---|---|
To: | gentoo-commits@l.g.o |
Subject: | [gentoo-commits] gentoo-x86 commit in games-action/powermanga/files: powermanga-0.90-segfault.patch |
Date: | Fri, 03 Aug 2012 04:26:09 |
Message-Id: | 20120803042558.EE31E2004C@flycatcher.gentoo.org |
1 | mr_bones_ 12/08/03 04:25:58 |
2 | |
3 | Added: powermanga-0.90-segfault.patch |
4 | Log: |
5 | patch from Daniel Santos to fix segfault (bug #422915) |
6 | |
7 | (Portage version: 2.1.10.65/cvs/Linux x86_64) |
8 | |
9 | Revision Changes Path |
10 | 1.1 games-action/powermanga/files/powermanga-0.90-segfault.patch |
11 | |
12 | file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/games-action/powermanga/files/powermanga-0.90-segfault.patch?rev=1.1&view=markup |
13 | plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/games-action/powermanga/files/powermanga-0.90-segfault.patch?rev=1.1&content-type=text/plain |
14 | |
15 | Index: powermanga-0.90-segfault.patch |
16 | =================================================================== |
17 | https://bugs.gentoo.org/show_bug.cgi?id=422915 |
18 | |
19 | --- tmp/powermanga-0.90.orig/src/shots.c 2007-08-24 00:55:17.000000000 -0700 |
20 | +++ powermanga-0.90-dfsg/src/shots.c 2011-12-26 21:10:28.000000000 -0800 |
21 | @@ -447,8 +447,6 @@ |
22 | { |
23 | bullet->img_angle = (Sint16) (bullet->angle / PI_SUR_16); |
24 | } |
25 | - /* save current angle for the calculation of the next angle */ |
26 | - bullet->img_old_angle = bullet->img_angle; |
27 | /* avoid negative indexes */ |
28 | bullet->img_angle = (Sint16) abs (bullet->img_angle); |
29 | /* avoid a shot angle higher than the number of images */ |
30 | @@ -456,6 +454,8 @@ |
31 | { |
32 | bullet->img_angle = (Sint16) (bullet->spr.numof_images - 1); |
33 | } |
34 | + /* save current angle for the calculation of the next angle */ |
35 | + bullet->img_old_angle = bullet->img_angle; |
36 | /* draw the shot sprite */ |
37 | draw_sprite (bullet->spr. |
38 | img[bullet->img_angle], |