Complete.Org: Mailing Lists: Archives: freeciv-ai: January 2003:
[freeciv-ai] (PR#2754) Server loops
Home

[freeciv-ai] (PR#2754) Server loops

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: rf13@xxxxxxxxxxxxxxxxx
Cc: freeciv-ai@xxxxxxxxxxx
Subject: [freeciv-ai] (PR#2754) Server loops
From: "Jason Short via RT" <rt@xxxxxxxxxxxxxx>
Date: Wed, 8 Jan 2003 00:35:47 -0800
Reply-to: rt@xxxxxxxxxxxxxx

[rfalke - Tue Jan  7 18:38:04 2003]:

> 
> The server hangs in this recursion:
> 
> #0  0x080cb81a in ai_manage_explorer (punit=0x81eeb50) at aiunit.c:477
> #1  0x0805a919 in handle_unit_activity_dependencies (punit=0x81eeb50,
>     old_activity=ACTIVITY_POLLUTION, old_target=0) at unithand.c:1242
> #2  0x0805aa84 in handle_unit_activity_request (punit=0x3,
>     new_activity=136244048) at unithand.c:1278
> #3  0x080c9d71 in ai_unit_goto (punit=0x3, x=0, y=0) at aitools.c:174
> #4  0x080cb44a in ai_manage_explorer (punit=0x81eeb50) at aiunit.c:506
> #5  0x0805a919 in handle_unit_activity_dependencies (punit=0x81eeb50,
>     old_activity=ACTIVITY_POLLUTION, old_target=0) at unithand.c:1242
> #6  0x0805aa84 in handle_unit_activity_request (punit=0x3,
>     new_activity=136244048) at unithand.c:1278
> #7  0x080c9d71 in ai_unit_goto (punit=0x3, x=0, y=0) at aitools.c:174
> #8  0x080cb44a in ai_manage_explorer (punit=0x81eeb50) at aiunit.c:506
> #9  0x0805a919 in handle_unit_activity_dependencies (punit=0x81eeb50,
>     old_activity=ACTIVITY_POLLUTION, old_target=0) at unithand.c:1242
> #10 0x0805aa84 in handle_unit_activity_request (punit=0x3,
>     new_activity=136244048) at unithand.c:1278
> #11 0x080c9d71 in ai_unit_goto (punit=0x3, x=0, y=0) at aitools.c:174
> #12 0x080cb44a in ai_manage_explorer (punit=0x81eeb50) at aiunit.c:506
> #13 0x0805a919 in handle_unit_activity_dependencies (punit=0x81eeb50,
>     old_activity=ACTIVITY_POLLUTION, old_target=0) at unithand.c:1242
> #14 0x0805aa84 in handle_unit_activity_request (punit=0x3,
>     new_activity=136244048) at unithand.c:1278
> 
> Reproducible: load the savegame and press multiple times the turn done
> button.

I suspect it was caused by the following commit to aitools.c:

date: 2002/12/02 22:48:13;  author: per;  state: Exp;  lines: +40 -0
Wrap the use of do_unit_goto() in the AI code behind two new goto
functions: ai_unit_goto() for short-term gotos (one turn horizon)
and ai_unit_gothere() for doing multi-turn missions.

which added the code that calls the recursion from the AI code back to
the server code.

jason



[Prev in Thread] Current Thread [Next in Thread]
  • [freeciv-ai] (PR#2754) Server loops, Jason Short via RT <=