Check for NULL in meta_screen_tab_popup_destroy() instead of asserting

This function is getting called even when no MetaAltTabHandler object is
installed on the screen, so we need to handle the NULL gracefully.
This commit is contained in:
Tomas Frydrych 2009-08-26 16:26:22 +01:00
parent c2c0de1696
commit 3e09b4a725

View File

@ -1563,7 +1563,8 @@ meta_screen_tab_popup_get_selected (MetaScreen *screen)
void
meta_screen_tab_popup_destroy (MetaScreen *screen)
{
g_return_if_fail (screen->tab_handler != NULL);
if (!screen->tab_handler)
return;
meta_alt_tab_handler_destroy (screen->tab_handler);
g_object_unref (screen->tab_handler);