[Freeciv-Dev] Re: (PR#13625) Crash in ruleset without Coinage
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://bugs.freeciv.org/Ticket/Display.html?id=13625 >
Marko Lindqvist wrote:
>
> My ruleset is crashing a lot lately. This is probably due to fact that it
> has no Coinage.
> I can't create patch from this machine, but at least one problem is
> get_improvement_name(id) call in ai/aitools.c:1162. It might be called when
> id == B_LAST.
Patch
- ML
diff -Nurd -X.diff_ignore freeciv/ai/aitools.c freeciv/ai/aitools.c
--- freeciv/ai/aitools.c 2005-08-20 22:25:29.328125000 +0300
+++ freeciv/ai/aitools.c 2005-08-20 22:35:02.765625000 +0300
@@ -1159,8 +1159,11 @@
choice->want = want;
choice->choice = id;
choice->type = CT_BUILDING;
- CITY_LOG(LOG_DEBUG, pcity, "wants most to build %s at %d",
- get_improvement_name(id), want);
+
+ if (id != B_LAST) {
+ CITY_LOG(LOG_DEBUG, pcity, "wants most to build %s at %d",
+ get_improvement_name(id), want);
+ }
}
/**********************************************************************
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] Re: (PR#13625) Crash in ruleset without Coinage,
Marko Lindqvist <=
|
|