--- a/src/menu.c
+++ b/src/menu.c
@@ -79,9 +79,9 @@
 
 static const char type[][8] = { "menubar", "popup" };
 
-const char *menu_get_tree_name (int tree)
-{
-  return (tree >= 0 && tree < G_N_ELEMENTS(type)) ? type[tree] : NULL;
+const char *menu_get_tree_name (unsigned int tree)
+{
+  return tree < G_N_ELEMENTS(type) ? type[tree] : NULL;
 }
 
 static void autoplay_cb (GtkAction *action, const char *data)
@@ -665,7 +665,7 @@
   action = ui_get_action_group (ui);
 
   xine_cfg_entry_t entry;
-  int i;
+  unsigned int i;
 
   for (i = 0; i < G_N_ELEMENTS(toggle_prefs); ++i)
     if (toggle_prefs[i] &&