string-list: allow case-insensitive string list
[gitweb.git] / string-list.h
index c50b0d0deac086cd5a50a5c021103a5f5e76c1cd..446e79e4255791a6855b659b8cf171d9e27323b7 100644 (file)
@@ -5,10 +5,14 @@ struct string_list_item {
        char *string;
        void *util;
 };
+
+typedef int (*compare_strings_fn)(const char *, const char *);
+
 struct string_list {
        struct string_list_item *items;
        unsigned int nr, alloc;
        unsigned int strdup_strings:1;
+       compare_strings_fn cmp; /* NULL uses strcmp() */
 };
 
 #define STRING_LIST_INIT_NODUP { NULL, 0, 0, 0 }