diff audacious/mainwin.c @ 813:c8cf439179b8 trunk

[svn] - Fix a ton and a half of memory leaks, via the wonderful Leonardo Boshell <leonardop -at- gentoo.org>.
author nenolod
date Fri, 10 Mar 2006 08:20:15 -0800
parents fbbd15125774
children 1125fdc111c2
line wrap: on
line diff
--- a/audacious/mainwin.c	Thu Mar 09 19:09:41 2006 -0800
+++ b/audacious/mainwin.c	Fri Mar 10 08:20:15 2006 -0800
@@ -161,7 +161,7 @@
 
 
 GtkWidget *mainwin = NULL;
-GtkMessageDialog *err = NULL; /* an error dialog for miscellaneous error messages */
+GtkWidget *err = NULL; /* an error dialog for miscellaneous error messages */
 
 static GdkBitmap *nullmask;
 static gint balance;
@@ -1390,6 +1390,7 @@
 
     gtk_tree_model_get(model, &iter, 0, &pos_str, -1);
     pos = g_ascii_strtoull(pos_str, NULL, 10) - 1;
+    g_free(pos_str);
 
     change_song(pos);
 
@@ -1461,6 +1462,7 @@
 
     gtk_tree_model_get(model, &iter, 0, &pos_str, -1);
     pos = g_ascii_strtoull(pos_str, NULL, 10) - 1;
+    g_free(pos_str);
 
     mainwin_jump_to_file_set_queue_button_label(GTK_BUTTON(data), pos);
 }
@@ -3152,9 +3154,9 @@
 
 
     gtk_window_set_position(GTK_WINDOW(err), GTK_WIN_POS_CENTER);
-    gtk_label_set_line_wrap(GTK_LABEL(err->label), TRUE);
     /* Dang well better set an error message or you'll see this */
-    gtk_message_dialog_format_secondary_text(err,"Boo! Bad stuff! Booga Booga!");
+    gtk_message_dialog_format_secondary_text(GTK_MESSAGE_DIALOG(err),
+                                             "Boo! Bad stuff! Booga Booga!");
 
 }