From 6964267c3764ba6d74e2d186926ccc03e65a3016 Mon Sep 17 00:00:00 2001 From: Enno Rehling Date: Mon, 19 Sep 2016 08:35:54 +0200 Subject: [PATCH] static variables, duh --- src/spells.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/spells.c b/src/spells.c index 63f3af6a3..380d41b54 100644 --- a/src/spells.c +++ b/src/spells.c @@ -1502,7 +1502,7 @@ static int sp_create_irongolem(castorder * co) double force = co->force; int number = lovar(force * 8 * RESOURCE_QUANTITY); static int cache; - const race * golem_rc; + static const race * golem_rc; if (rc_changed(&cache)) { golem_rc = rc_find("irongolem"); @@ -1570,7 +1570,8 @@ static int sp_create_stonegolem(castorder * co) unit *mage = co->magician.u; int cast_level = co->level; int number = lovar(co->force * 5 * RESOURCE_QUANTITY); - const race * golem_rc; + static int cache; + static const race * golem_rc; if (rc_changed(&cache)) { golem_rc = rc_find("stonegolem");