Complete.Org: Mailing Lists: Archives: freeciv-dev: December 2004:
[Freeciv-Dev] Re: (PR#11317) Beta4 crashes on SPARC/Solaris
Home

[Freeciv-Dev] Re: (PR#11317) Beta4 crashes on SPARC/Solaris

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: muehlber@xxxxxxxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#11317) Beta4 crashes on SPARC/Solaris
From: "Jason Short" <jdorje@xxxxxxxxxxxxxxxxxxxxx>
Date: Fri, 3 Dec 2004 10:55:15 -0800
Reply-to: rt@xxxxxxxxxxx

<URL: http://rt.freeciv.org/Ticket/Display.html?id=11317 >

Well, the bug is easy enough to spot.  Printf'ing a NULL string may work 
on linux but probably isn't so good.  I wonder how many more bug reports 
this is the cause of?

And, advances[].name is used in lots more places.  So even with this 
patch you may still get more crashes.  We should probably change them 
all to use get_tech_name, but in the meantime just continue to send us 
backtraces for any bugs you find.

jason


Index: server/plrhand.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/plrhand.c,v
retrieving revision 1.330.2.10
diff -u -r1.330.2.10 plrhand.c
--- server/plrhand.c    28 Nov 2004 16:01:51 -0000      1.330.2.10
+++ server/plrhand.c    3 Dec 2004 18:49:28 -0000
@@ -648,7 +648,7 @@
 
 void choose_tech_goal(struct player *plr, int tech)
 {
-  notify_player(plr, _("Game: Technology goal is %s."), advances[tech].name);
+  notify_player(plr, _("Game: Technology goal is %s."), get_tech_name(tech));
   plr->ai.tech_goal = tech;
 }
 

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