summaryrefslogtreecommitdiff
path: root/epan
diff options
context:
space:
mode:
authorGuy Harris <guy@alum.mit.edu>2014-10-28 11:18:40 -0700
committerGuy Harris <guy@alum.mit.edu>2014-10-28 18:19:15 +0000
commit8ea4df97e052f3fb0af3336990f2bef6d882b258 (patch)
treee4bfe40db402990be6cfe97abf646dc32769b7de /epan
parentbab44ad3dcb653821dce345b01e3c74ef698884b (diff)
downloadwireshark-8ea4df97e052f3fb0af3336990f2bef6d882b258.tar.gz
Use g_ascii_isalnum() rather than isalnum().
Only *ASCII* alphanumerics are allowed in filterable field names, so use g_ascii_isalnum() to check for them. That avoids issues with characters with the 8th bit set and avoids locale-dependent behavior. Change-Id: I4e3c4eec907f5e576629229fcf154fcf728b7a2e Reviewed-on: https://code.wireshark.org/review/4973 Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan')
-rw-r--r--epan/oids.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/epan/oids.c b/epan/oids.c
index 8bfff54e10..dbb7e79215 100644
--- a/epan/oids.c
+++ b/epan/oids.c
@@ -27,7 +27,6 @@
#include <glib.h>
#include <stdio.h>
#include <string.h>
-#include <ctype.h>
#include <wsutil/report_err.h>
@@ -274,7 +273,7 @@ static char* alnumerize(const char* name) {
char c;
for (;(c = *r); r++) {
- if (isalnum(c) || c == '_' || c == '-' || c == '.') {
+ if (g_ascii_isalnum(c) || c == '_' || c == '-' || c == '.') {
*(w++) = c;
} else if (c == ':' && r[1] == ':') {
*(w++) = '.';