diff console/libgnt/gntwm.c @ 15210:7d682fc9098f

[gaim-migrate @ 18000] Clicking the first window on the taskbar didn't give it focus. Fix that. committer: Tailor Script <tailor@pidgin.im>
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 15 Dec 2006 00:40:56 +0000
parents 92ebda7a7afc
children 995af0f20c27
line wrap: on
line diff
--- a/console/libgnt/gntwm.c	Thu Dec 14 22:25:18 2006 +0000
+++ b/console/libgnt/gntwm.c	Fri Dec 15 00:40:56 2006 +0000
@@ -300,10 +300,13 @@
 	GList *l;
 	int n;
 
-	if (!wm->ordered || !list)
+	if (!wm->ordered)
 		return TRUE;
 
-	n = GPOINTER_TO_INT(list->data);
+	if (list)
+		n = GPOINTER_TO_INT(list->data);
+	else
+		n = 0;
 	
 	w = wm->ordered->data;