Mercurial > geeqie
diff src/preferences.c @ 736:a7289f9e8d29
Fix signed vs unsigned warnings.
In most cases, gint was used instead of guint.
author | zas_ |
---|---|
date | Thu, 22 May 2008 13:00:45 +0000 |
parents | 57f759d012c7 |
children | ff51413f098d |
line wrap: on
line diff
--- a/src/preferences.c Thu May 22 11:28:35 2008 +0000 +++ b/src/preferences.c Thu May 22 13:00:45 2008 +0000 @@ -519,13 +519,14 @@ gint n; n = gtk_combo_box_get_active(GTK_COMBO_BOX(combo)); + if (n < 0) return; - if (n >= 0 && n < sizeof(thumb_size_list) / sizeof(ThumbSize)) + if ((guint) n < sizeof(thumb_size_list) / sizeof(ThumbSize)) { c_options->thumbnails.max_width = thumb_size_list[n].w; c_options->thumbnails.max_height = thumb_size_list[n].h; } - else if (n > 0) + else { c_options->thumbnails.max_width = options->thumbnails.max_width; c_options->thumbnails.max_height = options->thumbnails.max_height; @@ -546,7 +547,7 @@ combo = gtk_combo_box_new_text(); current = -1; - for (i = 0; i < sizeof(thumb_size_list) / sizeof(ThumbSize); i++) + for (i = 0; (guint) i < sizeof(thumb_size_list) / sizeof(ThumbSize); i++) { gint w, h; gchar *buf;