# HG changeset patch # User Yoshiki Yazawa # Date 1198007420 -32400 # Node ID a3fc19130dce6e1d021ebffb10cd12e151a0d668 # Parent b03055a1437a13562b925246ed987bb7561d2581 add workaround to deadlock which occurs when "create a new playlist with matching entries" is checked in search and select dialog. diff -r b03055a1437a -r a3fc19130dce src/audacious/ui_playlist_manager.c --- a/src/audacious/ui_playlist_manager.c Wed Dec 19 01:44:09 2007 +0900 +++ b/src/audacious/ui_playlist_manager.c Wed Dec 19 04:50:20 2007 +0900 @@ -66,12 +66,16 @@ gchar *pl_name = NULL; Playlist *playlist = (Playlist*)playlists->data; - PLAYLIST_LOCK(playlist); + if(playlist != active) //XXX the active playlist has been locked in playlist_new_from_selected() + PLAYLIST_LOCK(playlist); + /* for each playlist, pick name and number of entries */ pl_name = (gchar*)playlist_get_current_name( playlist ); for (entries = playlist->entries; entries; entries = g_list_next(entries)) entriesnum++; - PLAYLIST_UNLOCK(playlist); + + if(playlist != active) + PLAYLIST_UNLOCK(playlist); /* update the tree model conservatively */