mirror of
https://github.com/transmission/transmission
synced 2025-02-03 21:12:05 +00:00
(trunk gtk) #2500 "Torrent details window should be single-instance per torrent" -- fix implementation bug from r9685 that caused the same memory to be freed twice on shutdown
This commit is contained in:
parent
f293bb97be
commit
d686257320
1 changed files with 3 additions and 12 deletions
15
gtk/main.c
15
gtk/main.c
|
@ -781,18 +781,9 @@ onSessionClosed( gpointer gdata )
|
|||
struct cbdata * cbdata = gdata;
|
||||
|
||||
/* shutdown the gui */
|
||||
if( cbdata->details != NULL )
|
||||
{
|
||||
GSList * l;
|
||||
for( l=cbdata->details; l!=NULL; l=l->next )
|
||||
{
|
||||
struct DetailsDialogHandle * h = l->data;
|
||||
gtk_widget_destroy( h->dialog );
|
||||
g_free( h->key );
|
||||
g_free( h );
|
||||
}
|
||||
g_slist_free( cbdata->details );
|
||||
cbdata->details = NULL;
|
||||
while( cbdata->details != NULL ) {
|
||||
struct DetailsDialogHandle * h = cbdata->details->data;
|
||||
gtk_widget_destroy( h->dialog );
|
||||
}
|
||||
|
||||
if( cbdata->prefs )
|
||||
|
|
Loading…
Reference in a new issue