Complete.Org: Mailing Lists: Archives: freeciv-dev: October 2001:
[Freeciv-Dev] Re: civserver crash (PR#1005)
Home

[Freeciv-Dev] Re: civserver crash (PR#1005)

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
Cc: freeciv-dev@xxxxxxxxxxx, bugs@xxxxxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: civserver crash (PR#1005)
From: Jason Dorje Short <vze2zq63@xxxxxxxxxxx>
Date: Fri, 12 Oct 2001 04:59:58 -0400
Reply-to: jdorje@xxxxxxxxxxxx

Raimar Falke wrote:
> 
> On Thu, Oct 11, 2001 at 03:13:16PM -0700, jdorje@xxxxxxxxxxxxxxxxxxxxx wrote:
> > I had patched civclient slightly, but nothing outside of the client/
> > directory was changed.  civserver crashed upon game start.  Could be
> > that the client sent some bad information to the server, but this
> > shouldn't cause a server crash.  It appears to be reproducable, with or
> > without the modifications to the client.

> I can't reproduce this.

This is the server for Freeciv version 1.12.1-devel
You can learn a lot about Freeciv at http://www.freeciv.org/
2: Now accepting new client connections.

For introductory help, type 'help'.
> 
2: Connection request from jshort from localhost.localdomain
2: jshort has client version 1.12.1-devel
2: jshort has joined as player jshort.
> aitoggle jshort
jshort is now under AI control.
jshort is now easy.
> set aifill 2
Option: aifill has been set to 2.
> hard
jshort is now hard.
Setting game.skill_level to 7.
> start
Starting game.
2: Loading rulesets
2: AI is controlling the Scots ruled by jshort.
2: Milos Obrenovic has been added as an AI-controlled player.
2: AI is controlling the Serbians ruled by Milos Obrenovic.
Milos Obrenovic is now hard.
Segmentation fault (core dumped)

Still happens.  I'm now using current CVS...

I'll try recompiling; perhaps some of the timestamps are bad and an
object file isn't getting properly updated.

> Can you give extra information? For example the offset would be
> interesting.

Upon further review I am...confused.  [Note: the following is not from
the same crash but a different similar one.]

#0  0x08070837 in map_get_known_and_seen (x=44, y=22, pplayer=0x812845c)
at maphand.c:780
780       return ((map.tiles + offset)->known) & (1u << playerid) &&
(gdb) bt
#0  0x08070837 in map_get_known_and_seen (x=44, y=22, pplayer=0x812845c)
at maphand.c:780
#1  0x080704ed in really_show_area (pplayer=0x812845c, x=44, y=22) at
maphand.c:700
#2  0x080706f3 in show_area (pplayer=0x812845c, x=45, y=23, len=1) at
maphand.c:745
#3  0x080670b1 in init_new_game () at gamehand.c:136
#4  0x0804ef52 in srv_main () at srv_main.c:1963
#5  0x08049b79 in main (argc=3, argv=0xbffff954) at civserver.c:147
#6  0x40076177 in __libc_start_main (main=0x8049660 <main>, argc=3,
ubp_av=0xbffff954, init=0x8049060 <_init>, fini=0x80b33b0 <_fini>,
rtld_fini=0x4000e184 <_dl_fini>, stack_end=0xbffff94c)
    at ../sysdeps/generic/libc-start.c:129
(gdb) p offset
$1 = 1804
(gdb) p map.xsize
$2 = 80
(gdb) p map.ysize
$3 = 50
(gdb) p map.xsize * map.ysize
$4 = 4000
(gdb) p map.tiles
$5 = (struct tile *) 0x81e8820
(gdb) p map.tiles[offset]
$6 = {terrain = T_PLAINS, special = S_SPECIAL_2, city = 0x0, units =
{list = {nelements = 0, null_link = {next = 0x8204b30, prev = 0x8204b30,
dataptr = 0x0}, head_link = 0x8204b30, tail_link = 0x8204b30}}, 
  known = 0, sent = 1, assigned = 0, worked = 0x0, continent = 5,
move_cost = "\003\003\003\003\003\003\003\003"}
(gdb) p (map.tiles + offset)
$7 = (struct tile *) 0x8204b20
(gdb) p (map.tiles + offset)->known
$8 = 0
(gdb) p pplayer->private_map
$13 = (struct player_tile *) 0x823d800
(gdb) p pplayer->private_map[offset]
$14 = {terrain = T_UNKNOWN, special = S_NO_SPECIAL, seen = 0, own_seen =
0, pending_seen = 0, city = 0x0, last_updated = -4000}
(gdb) p ((map.tiles + offset)->known) & (1u << playerid) &&
(pplayer->private_map + offset)->seen
$15 = 0


jason


[Prev in Thread] Current Thread [Next in Thread]