From bb8debf18f818e23c474386cd801405ad3b32e16 Mon Sep 17 00:00:00 2001 From: Eric Wasylishen Date: Fri, 28 Jul 2017 20:50:25 +0000 Subject: [PATCH] sv_move.c: add explicit int cast to a float argument to abs(). Previously, the cast was implicit since abs() takes an int, so there is no change in behaviour. Suppresses a clang warning that we might want fabs(). git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@1451 af15c1b1-3010-417e-b628-4374ebc0bcbd --- Quake/sv_move.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Quake/sv_move.c b/Quake/sv_move.c index 29116522..fd190848 100644 --- a/Quake/sv_move.c +++ b/Quake/sv_move.c @@ -320,7 +320,7 @@ void SV_NewChaseDir (edict_t *actor, edict_t *enemy, float dist) } // try other directions - if ( ((rand()&3) & 1) || abs(deltay)>abs(deltax)) + if ( ((rand()&3) & 1) || abs((int)deltay)>abs((int)deltax)) // ericw -- explicit int cast to suppress clang suggestion to use fabsf { tdir=d[1]; d[1]=d[2];