diff options
author | Fabian Greffrath | 2015-05-08 08:57:20 +0200 |
---|---|---|
committer | Fabian Greffrath | 2015-05-08 08:57:20 +0200 |
commit | 744697c4fe213821c18dd882098b311550d42da7 (patch) | |
tree | 6cb2f3e9a4a2b338412b97a03d20e01ae4d1f2d9 /src/hexen | |
parent | 2e8f6da6fdf0eb71e58d2cdaad24e5b0a332f675 (diff) | |
download | chocolate-doom-744697c4fe213821c18dd882098b311550d42da7.tar.gz chocolate-doom-744697c4fe213821c18dd882098b311550d42da7.tar.bz2 chocolate-doom-744697c4fe213821c18dd882098b311550d42da7.zip |
warnings: fix "iteration XY invokes undefined behavior" warnings
These were caused by loops which caused overflow of variables of type
angle_t (= unsigned) by multiplication with iterators of typed int in
angle calculations. Changing the type of the iterator variables to
"unsigned int" prevents the undefined behavior.
Diffstat (limited to 'src/hexen')
-rw-r--r-- | src/hexen/p_enemy.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/hexen/p_enemy.c b/src/hexen/p_enemy.c index dc2c9fe5..38f3a2b5 100644 --- a/src/hexen/p_enemy.c +++ b/src/hexen/p_enemy.c @@ -3855,7 +3855,7 @@ void A_IceGuyDie(mobj_t * actor) void A_IceGuyMissileExplode(mobj_t * actor) { mobj_t *mo; - int i; + unsigned int i; for (i = 0; i < 8; i++) { |