Skip to content

Commit 68a8c2a

Browse files
jefdriesenmikeller
authored andcommitted
Use a case-insensitive comparision
The other prefix matching function already use a case-insensitive comparision. There is no reason for a different behaviour.
1 parent 5edc563 commit 68a8c2a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/descriptor.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -549,7 +549,7 @@ dc_match_prefix_with_number (const void *key, const void *value)
549549

550550
size_t n = strlen (prefix);
551551

552-
if (strncmp (str, prefix, n) != 0) {
552+
if (strncasecmp (str, prefix, n) != 0) {
553553
return 0;
554554
}
555555

@@ -572,7 +572,7 @@ dc_match_prefix_with_hex (const void *key, const void *value)
572572

573573
size_t n = strlen (prefix);
574574

575-
if (strncmp (str, prefix, n) != 0) {
575+
if (strncasecmp (str, prefix, n) != 0) {
576576
return 0;
577577
}
578578

0 commit comments

Comments
 (0)