summary refs log tree commit diff stats
path: root/src/fe-gtk/custom-list.c
diff options
context:
space:
mode:
authorArnavion <arnavion@gmail.com>2014-12-04 04:06:38 -0800
committerArnavion <arnavion@gmail.com>2014-12-04 04:06:38 -0800
commit8062bce835681d8200666ad183fe8cf3f6d87468 (patch)
treee81450df3b1b71d763695c9832edb3ffca265255 /src/fe-gtk/custom-list.c
parent3fbe5b876e3af3fde135eb42bcd3050b41865d1a (diff)
Fix some obvious type warnings.
Diffstat (limited to 'src/fe-gtk/custom-list.c')
-rw-r--r--src/fe-gtk/custom-list.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/fe-gtk/custom-list.c b/src/fe-gtk/custom-list.c
index a954b4a0..f67c3c07 100644
--- a/src/fe-gtk/custom-list.c
+++ b/src/fe-gtk/custom-list.c
@@ -336,7 +336,7 @@ custom_list_get_iter (GtkTreeModel * tree_model,
 	gint n;
 
 	n = gtk_tree_path_get_indices (path)[0];
-	if (n >= custom_list->num_rows || n < 0)
+	if (n < 0 || (guint) n >= custom_list->num_rows)
 		return FALSE;
 
 	record = custom_list->rows[n];
@@ -533,7 +533,7 @@ custom_list_iter_nth_child (GtkTreeModel * tree_model,
 		return FALSE;
 
 	/* special case: if parent == NULL, set iter to n-th top-level row */
-	if (n >= custom_list->num_rows)
+	if (n < 0 || (guint) n >= custom_list->num_rows)
 		return FALSE;
 
 	iter->user_data = custom_list->rows[n];