From: proski Date: Mon, 6 Jul 2009 20:07:58 +0000 (+0000) Subject: 2009-07-06 Daniel Mierswa X-Git-Tag: 1.98~727 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=e110f4dea79c5f1e934b9686e39ada893608d876;p=thirdparty%2Fgrub.git 2009-07-06 Daniel Mierswa * commands/search.c (search_fs): Use grub_strcasecmp() for UUID comparison. --- diff --git a/ChangeLog b/ChangeLog index db77c5d6b..521a32c54 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2009-07-06 Daniel Mierswa + + * commands/search.c (search_fs): Use grub_strcasecmp() for UUID + comparison. + 2009-07-05 Pavel Roskin * include/grub/i386/linux.h (struct linux_kernel_params): diff --git a/commands/search.c b/commands/search.c index 647f40839..d749bca11 100644 --- a/commands/search.c +++ b/commands/search.c @@ -67,8 +67,10 @@ search_fs (const char *key, const char *var, int no_floppy, int is_uuid) if (dev) { grub_fs_t fs; + int (*compare_fn) (const char *, const char *); fs = grub_fs_probe (dev); + compare_fn = is_uuid ? grub_strcasecmp : grub_strcmp; #define QUID(x) (is_uuid ? (x)->uuid : (x)->label) @@ -79,7 +81,7 @@ search_fs (const char *key, const char *var, int no_floppy, int is_uuid) (QUID(fs)) (dev, &quid); if (grub_errno == GRUB_ERR_NONE && quid) { - if (grub_strcmp (quid, key) == 0) + if (compare_fn (quid, key) == 0) { /* Found! */ count++;