Complete.Org: Mailing Lists: Archives: freeciv-dev: October 2003:
[Freeciv-Dev] Re: (PR#977) Re: (PR#4638) Connect Dialog Patch
Home

[Freeciv-Dev] Re: (PR#977) Re: (PR#4638) Connect Dialog Patch

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: dspeyer@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#977) Re: (PR#4638) Connect Dialog Patch
From: "Christian Knoke" <chrisk@xxxxxxxxx>
Date: Thu, 16 Oct 2003 13:11:35 -0700
Reply-to: rt@xxxxxxxxxxxxxx

On Sun, Oct 12, 2003 at 03:10:15AM -0700, Per I. Mathisen wrote:
> 
> I wanted badly to test this patch, so I fixed the compile errors (missing
> entries in Makefile.am, experimental skill level overflow, lots of
> warnings), and while I was at it I cleaned up a lot of bad style stuff.
> Patch attached.

Core was generated by `civserver -p 5555 --debug 3 --log -'.
Program terminated with signal 11, Segmentation fault.

251         if (ai->government_want[gov->index] > best_val 
(gdb) bt
#0  0x080c90dc in ai_best_government (pplayer=0x81fdfe8) at aihand.c:251
#1  0x080c881f in ai_data_turn_init (pplayer=0x81fdfe8) at aidata.c:305
#2  0x0804e0b0 in begin_turn () at srv_main.c:468
#3  0x0804f9cc in main_loop () at srv_main.c:1476
#4  0x080501b0 in srv_loop () at srv_main.c:1843
#5  0x0804fc2a in srv_main () at srv_main.c:1630
#6  0x0804a337 in main (argc=7, argv=0xbffff424) at civserver.c:154
#7  0x400a07ee in __libc_start_main () from /lib/libc.so.6

I patched against Oct 14 CVS. There had been 1 reject, which I applied
manually:

chris@max:~/freeciv/patched/conn17> cat server/gamelog.c.rej 
***************
*** 59,65 ****
    if (level > gamelog_level)
      return;
  
-   fs=fopen(gamelog_filename, "a");
    if (!fs) {
      freelog(LOG_FATAL, _("Couldn't open gamelogfile \"%s\" for
appending."), 
            gamelog_filename);
--- 59,69 ----
    if (level > gamelog_level)
      return;
  
+   if (!strcmp(gamelog_filename, "-")){
+     fs=stderr;
+   }else{
+     fs=fopen(gamelog_filename, "a");
+   }
    if (!fs) {
      freelog(LOG_FATAL, _("Couldn't open gamelogfile \"%s\" for
appending."), 
            gamelog_filename);

Christian

-- 
Christian Knoke            * * *            http://cknoke.de
* Dear M$, I know your OS sucks, you really don't need to  *
* tell me 10 times a day ...                               *
* * * * * * * * *  Ceterum censeo Microsoft esse dividendum.



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