summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
Diffstat (limited to 'lib')
-rw-r--r--lib/icmp.c2
-rw-r--r--lib/icmpv6.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/lib/icmp.c b/lib/icmp.c
index 93276e2..c749272 100644
--- a/lib/icmp.c
+++ b/lib/icmp.c
@@ -70,7 +70,7 @@ int name_to_icmp(const char *str, uint16_t *typecode)
unsigned int i;
for (i = 0; i < ARRAY_SIZE(icmp_typecodes); i++)
- if (STRNEQ(icmp_typecodes[i].name, str, strlen(str))) {
+ if (STRNCASEQ(icmp_typecodes[i].name, str, strlen(str))) {
*typecode = (icmp_typecodes[i].type << 8) | icmp_typecodes[i].code;
return 0;
}
diff --git a/lib/icmpv6.c b/lib/icmpv6.c
index c32a6a4..5ba93ca 100644
--- a/lib/icmpv6.c
+++ b/lib/icmpv6.c
@@ -57,7 +57,7 @@ int name_to_icmpv6(const char *str, uint16_t *typecode)
unsigned int i;
for (i = 0; i < ARRAY_SIZE(icmpv6_typecodes); i++)
- if (STRNEQ(icmpv6_typecodes[i].name, str, strlen(str))) {
+ if (STRNCASEQ(icmpv6_typecodes[i].name, str, strlen(str))) {
*typecode = (icmpv6_typecodes[i].type << 8) | icmpv6_typecodes[i].code;
return 0;
}