[Freeciv-Dev] Re: (PR#9975) BUG: client gtk 2 crash aftet clic on refres
[Top] [All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
<URL: http://rt.freeciv.org/Ticket/Display.html?id=9975 >
Good report. This is a bug in the PR#1824 patch. The gtk2 client used
to strdup these strings. I removed the strdup (in the ntoh_str call)
but not the freeing of them. The crash happens in the second free call
even though that's the one that is correct.
jason
Index: client/gui-gtk-2.0/connectdlg.c
===================================================================
RCS file: /home/freeciv/CVS/freeciv/client/gui-gtk-2.0/connectdlg.c,v
retrieving revision 1.39
diff -u -r1.39 connectdlg.c
--- client/gui-gtk-2.0/connectdlg.c 6 Sep 2004 17:13:06 -0000 1.39
+++ client/gui-gtk-2.0/connectdlg.c 7 Sep 2004 23:09:19 -0000
@@ -1127,7 +1127,6 @@
server_list_iterate(*server_list, pserver) {
GtkTreeIter it;
- int i;
row[0] = pserver->name;
row[1] = pserver->port;
@@ -1140,10 +1139,6 @@
gtk_list_store_set(storemeta, &it,
0, row[0], 1, row[1], 2, row[2],
3, row[3], 4, row[4], 5, row[5], -1);
-
- for (i=0; i<6; i++) {
- g_free(row[i]);
- }
}
server_list_iterate_end;
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Freeciv-Dev] Re: (PR#9975) BUG: client gtk 2 crash aftet clic on refresh methaserver,
Jason Short <=
|
|