summaryrefslogtreecommitdiffstats
path: root/lib/match.c
diff options
context:
space:
mode:
authorKarel Zak2017-08-31 14:15:23 +0200
committerKarel Zak2017-08-31 14:15:23 +0200
commit0158e68fbd97ad6db062abcb3cbf0b3bf06e39b9 (patch)
tree2cd2909dbb27a7601a94179239547005e7b5e7f3 /lib/match.c
parentbuild-sys: add --disable-rfkill (diff)
downloadkernel-qcow2-util-linux-0158e68fbd97ad6db062abcb3cbf0b3bf06e39b9.tar.gz
kernel-qcow2-util-linux-0158e68fbd97ad6db062abcb3cbf0b3bf06e39b9.tar.xz
kernel-qcow2-util-linux-0158e68fbd97ad6db062abcb3cbf0b3bf06e39b9.zip
lib/match: make match_fstype() case insensitive
Signed-off-by: Karel Zak <kzak@redhat.com>
Diffstat (limited to 'lib/match.c')
-rw-r--r--lib/match.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/match.c b/lib/match.c
index 9be82b0cc..a286a190c 100644
--- a/lib/match.c
+++ b/lib/match.c
@@ -39,10 +39,10 @@ int match_fstype(const char *type, const char *pattern)
len = strlen(type);
p = pattern;
while(1) {
- if (!strncmp(p, "no", 2) && !strncmp(p+2, type, len) &&
+ if (!strncmp(p, "no", 2) && !strncasecmp(p+2, type, len) &&
(p[len+2] == 0 || p[len+2] == ','))
return 0;
- if (strncmp(p, type, len) == 0 && (p[len] == 0 || p[len] == ','))
+ if (strncasecmp(p, type, len) == 0 && (p[len] == 0 || p[len] == ','))
return !no;
p = strchr(p,',');
if (!p)