Complete.Org: Mailing Lists: Archives: freeciv-dev: April 2004:
[Freeciv-Dev] Re: (PR#8547) GCC poisoning v2
Home

[Freeciv-Dev] Re: (PR#8547) GCC poisoning v2

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: per@xxxxxxxxxxx
Subject: [Freeciv-Dev] Re: (PR#8547) GCC poisoning v2
From: "Raimar Falke" <i-freeciv-lists@xxxxxxxxxxxxx>
Date: Wed, 21 Apr 2004 12:19:16 -0700
Reply-to: rt@xxxxxxxxxxx

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

On Tue, Apr 20, 2004 at 11:22:36PM -0700, Raimar Falke wrote:

And the patch. Untested and not touching amiga or mui code.

        Raimar

-- 
 email: rf13@xxxxxxxxxxxxxxxxx
  This message has been ROT-13 encrypted twice for extra security.

Index: client/gui-gtk-2.0/citydlg.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/citydlg.c,v
retrieving revision 1.81
diff -u -u -r1.81 citydlg.c
--- client/gui-gtk-2.0/citydlg.c        4 Apr 2004 14:49:10 -0000       1.81
+++ client/gui-gtk-2.0/citydlg.c        21 Apr 2004 19:11:40 -0000
@@ -1529,8 +1529,8 @@
                   1, MAX(n, 1));
 
   pdialog->overview.supported_unit_nodes =
-    realloc(pdialog->overview.supported_unit_nodes,
-           n * sizeof(*pdialog->overview.supported_unit_nodes));
+      fc_realloc(pdialog->overview.supported_unit_nodes,
+                n * sizeof(*pdialog->overview.supported_unit_nodes));
   
   for (i=pdialog->overview.supported_unit_no; i<n; i++) {
     int unit_height = (is_isometric) ?
@@ -1629,8 +1629,8 @@
                   1, MAX(n, 1));
 
   pdialog->overview.present_unit_nodes =
-    realloc(pdialog->overview.present_unit_nodes,
-           n * sizeof(*pdialog->overview.present_unit_nodes));
+      fc_realloc(pdialog->overview.present_unit_nodes,
+                n * sizeof(*pdialog->overview.present_unit_nodes));
   
   for (i=pdialog->overview.present_unit_no; i<n; i++) {
     GtkWidget *cmd, *pix;
Index: client/gui-win32/menu.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-win32/menu.c,v
retrieving revision 1.18
diff -u -u -r1.18 menu.c
--- client/gui-win32/menu.c     1 Apr 2004 23:46:25 -0000       1.18
+++ client/gui-win32/menu.c     21 Apr 2004 19:11:43 -0000
@@ -233,8 +233,8 @@
   plus++;
   tab++;
   /* fkeys */
-  if ((*plus=='F')&&(isdigit(plus[1]))) {
-    if (isdigit(plus[2]))
+  if ((*plus == 'F') && (my_isdigit(plus[1]))) {
+    if (my_isdigit(plus[2]))
       newaccel.key=VK_F10+(plus[2]-'0');
     else
       newaccel.key=VK_F1+(plus[1]-'1');
Index: client/gui-xaw/cityrep.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-xaw/cityrep.c,v
retrieving revision 1.53
diff -u -u -r1.53 cityrep.c
--- client/gui-xaw/cityrep.c    28 Nov 2003 17:37:20 -0000      1.53
+++ client/gui-xaw/cityrep.c    21 Apr 2004 19:11:43 -0000
@@ -525,7 +525,7 @@
                                  n_alloc*sizeof(*cities_in_list));
       city_list_text = fc_realloc(city_list_text, n_alloc*sizeof(char*));
       for(j=n_prev; j<n_alloc; j++) {
-       city_list_text[j] = malloc(MAX_LEN_CITY_TEXT);
+       city_list_text[j] = fc_malloc(MAX_LEN_CITY_TEXT);
       }
     }
        
Index: server/sernet.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/server/sernet.c,v
retrieving revision 1.116
diff -u -u -r1.116 sernet.c
--- server/sernet.c     17 Mar 2004 00:22:44 -0000      1.116
+++ server/sernet.c     21 Apr 2004 19:11:45 -0000
@@ -745,7 +745,8 @@
       pconn->server.authentication_tries = 0;
       pconn->server.authentication_stop = 0;
       pconn->server.status = AS_NOT_ESTABLISHED;
-      pconn->server.ping_timers = malloc(sizeof(*pconn->server.ping_timers));
+      pconn->server.ping_timers =
+         fc_malloc(sizeof(*pconn->server.ping_timers));
       timer_list_init(pconn->server.ping_timers);
       pconn->ping_time = -1.0;
       pconn->incoming_packet_notify = NULL;

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