Fix some obvious type warnings.

This commit is contained in:
Arnavion
2014-12-04 04:06:38 -08:00
parent 3fbe5b876e
commit 8062bce835
18 changed files with 152 additions and 183 deletions

View File

@@ -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];