From 58f873acf482123bfc29c82096b6f35b7eee6b33 Mon Sep 17 00:00:00 2001 From: Giel van Schijndel Date: Sun, 6 May 2007 18:06:51 +0000 Subject: [PATCH] * Check source pointer for a value of NULL rather than another pointer (in the save droid) which we don't use (should cause no difference in execution due to the above memcpy call) Thanks to Hylke/The_Noid for reporting this. git-svn-id: svn+ssh://svn.gna.org/svn/warzone/trunk@1594 4a71c877-e1ca-e34f-864e-861f7616d084 --- src/game.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/game.c b/src/game.c index f9c41e61d..0e75bfa6b 100644 --- a/src/game.c +++ b/src/game.c @@ -6087,7 +6087,7 @@ static BOOL buildSaveDroidFromDroid(SAVE_DROID* psSaveDroid, DROID* psCurr, DROI //version 24 psSaveDroid->resistance = psCurr->resistance; memcpy(&psSaveDroid->sMove, &psCurr->sMove, sizeof(SAVE_MOVE_CONTROL)); - if (psSaveDroid->sMove.psFormation != NULL) + if (psCurr->sMove.psFormation != NULL) { psSaveDroid->formationDir = psCurr->sMove.psFormation->dir; psSaveDroid->formationX = psCurr->sMove.psFormation->x;