aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--epan/dissectors/packet-at.c2
-rw-r--r--epan/dissectors/packet-bjnp.c2
-rw-r--r--epan/dissectors/packet-ftp.c2
-rw-r--r--epan/dissectors/packet-osc.c2
-rw-r--r--epan/dissectors/packet-radius.c2
-rw-r--r--epan/dissectors/packet-slimp3.c4
-rw-r--r--epan/dissectors/packet-ssl-utils.c2
-rw-r--r--epan/uat.c4
-rw-r--r--ui/cli/tap-follow.c2
-rw-r--r--ui/qt/follow_stream_dialog.cpp4
-rw-r--r--wiretap/k12.c2
-rw-r--r--wsutil/str_util.c2
12 files changed, 15 insertions, 15 deletions
diff --git a/epan/dissectors/packet-at.c b/epan/dissectors/packet-at.c
index 760a965fe4..d1516ceecc 100644
--- a/epan/dissectors/packet-at.c
+++ b/epan/dissectors/packet-at.c
@@ -49,7 +49,7 @@ static gboolean allowed_chars(tvbuff_t *tvb)
len = tvb_length(tvb);
for (offset = 0; offset < len; offset++) {
val = tvb_get_guint8(tvb, offset);
- if (!(isprint(val) || (val == 0x0a) || (val == 0x0d)))
+ if (!(g_ascii_isprint(val) || (val == 0x0a) || (val == 0x0d)))
return (FALSE);
}
return (TRUE);
diff --git a/epan/dissectors/packet-bjnp.c b/epan/dissectors/packet-bjnp.c
index 8cc676bd9f..b37a3b68f1 100644
--- a/epan/dissectors/packet-bjnp.c
+++ b/epan/dissectors/packet-bjnp.c
@@ -99,7 +99,7 @@ static int dissect_bjnp (tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, vo
gchar *info;
/* If it does not start with a printable character it's not BJNP */
- if(!isprint(tvb_get_guint8(tvb, 0)))
+ if(!g_ascii_isprint(tvb_get_guint8(tvb, 0)))
return 0;
col_set_str (pinfo->cinfo, COL_PROTOCOL, PSNAME);
diff --git a/epan/dissectors/packet-ftp.c b/epan/dissectors/packet-ftp.c
index 9b338d1f30..53bc48965a 100644
--- a/epan/dissectors/packet-ftp.c
+++ b/epan/dissectors/packet-ftp.c
@@ -911,7 +911,7 @@ dissect_ftpdata(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree)
/* Check the first few chars to see whether it looks like a text file or not */
check_chars = MIN(10, data_length);
for (i=0; i < check_chars; i++) {
- if (!isprint(tvb_get_guint8(tvb, i))) {
+ if (!g_ascii_isprint(tvb_get_guint8(tvb, i))) {
is_text = FALSE;
break;
}
diff --git a/epan/dissectors/packet-osc.c b/epan/dissectors/packet-osc.c
index 39dc1d07e9..eee27fb2e4 100644
--- a/epan/dissectors/packet-osc.c
+++ b/epan/dissectors/packet-osc.c
@@ -257,7 +257,7 @@ is_valid_path(const char *path)
if(path[0] != '/')
return FALSE;
for(ptr=path+1; *ptr!='\0'; ptr++)
- if( (isprint(*ptr) == 0) || (strchr(invalid_path_chars, *ptr) != NULL) )
+ if( (g_ascii_isprint(*ptr) == 0) || (strchr(invalid_path_chars, *ptr) != NULL) )
return FALSE;
return TRUE;
}
diff --git a/epan/dissectors/packet-radius.c b/epan/dissectors/packet-radius.c
index 414564ba01..9871bdaac3 100644
--- a/epan/dissectors/packet-radius.c
+++ b/epan/dissectors/packet-radius.c
@@ -578,7 +578,7 @@ radius_decrypt_avp(gchar *dest,int dest_len,tvbuff_t *tvb,int offset,int length)
for ( i = 0; i < padded_length; i += AUTHENTICATOR_LENGTH ) {
for ( j = 0; j < AUTHENTICATOR_LENGTH; j++ ) {
c = pd[i + j] ^ digest[j];
- if ( isprint(c) ) {
+ if ( g_ascii_isprint(c) ) {
returned_length = g_snprintf(&dest[totlen], dest_len - totlen,
"%c", c);
totlen += MIN(returned_length, dest_len - totlen - 1);
diff --git a/epan/dissectors/packet-slimp3.c b/epan/dissectors/packet-slimp3.c
index b5fa0577a8..e2558ee70a 100644
--- a/epan/dissectors/packet-slimp3.c
+++ b/epan/dissectors/packet-slimp3.c
@@ -353,7 +353,7 @@ dissect_slimp3(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
break;
case 3:
lcd_char = tvb_get_guint8(tvb, offset + i1 + 1);
- if (!isprint(lcd_char))
+ if (!g_ascii_isprint(lcd_char))
lcd_char = '.';
if (ti && in_str) {
lcd_strlen += 2;
@@ -420,7 +420,7 @@ dissect_slimp3(tvbuff_t *tvb, packet_info *pinfo, proto_tree *tree, void *data _
(lcd_str[lcd_strlen-1] != ' ') ||
(tvb_get_guint8(tvb, offset + i1 + 1) != ' ')) {
lcd_char = tvb_get_guint8(tvb, offset + i1 + 1);
- lcd_str[lcd_strlen++] = isprint(lcd_char) ? lcd_char : '.';
+ lcd_str[lcd_strlen++] = g_ascii_isprint(lcd_char) ? lcd_char : '.';
}
}
}
diff --git a/epan/dissectors/packet-ssl-utils.c b/epan/dissectors/packet-ssl-utils.c
index 248e827e13..28bbeca22c 100644
--- a/epan/dissectors/packet-ssl-utils.c
+++ b/epan/dissectors/packet-ssl-utils.c
@@ -4650,7 +4650,7 @@ ssl_print_data(const gchar* name, const guchar* data, size_t len)
fputc('|', ssl_debug_file);
for (j=i, k=0; k<16 && j<len; ++j, ++k) {
guchar c = data[j];
- if (!isprint(c) || (c=='\t')) c = '.';
+ if (!g_ascii_isprint(c) || (c=='\t')) c = '.';
fputc(c, ssl_debug_file);
}
for (; k<16; ++k)
diff --git a/epan/uat.c b/epan/uat.c
index 8c3ecc82bf..923e310b6c 100644
--- a/epan/uat.c
+++ b/epan/uat.c
@@ -247,7 +247,7 @@ static void putfld(FILE* fp, void* rec, uat_field_t* f) {
for(i=0;i<fld_len;i++) {
char c = fld_ptr[i];
- if (c == '"' || c == '\\' || ! isprint((guchar)c) ) {
+ if (c == '"' || c == '\\' || ! g_ascii_isprint((guchar)c) ) {
fprintf(fp,"\\x%.2x",c);
} else {
putc(c,fp);
@@ -696,7 +696,7 @@ char* uat_esc(const char* buf, guint len) {
char* s = out;
for (b = (const guint8 *)buf; b < end; b++) {
- if (isprint(*b) ) {
+ if (g_ascii_isprint(*b) ) {
*(s++) = (*b);
} else {
g_snprintf(s,5,"\\x%.2x",((guint)*b));
diff --git a/ui/cli/tap-follow.c b/ui/cli/tap-follow.c
index 0418eefad9..90a4cf360e 100644
--- a/ui/cli/tap-follow.c
+++ b/ui/cli/tap-follow.c
@@ -665,7 +665,7 @@ followDraw(
data[ii] = bin[ii];
break;
default:
- data[ii] = isprint(bin[ii]) ? bin[ii] : '.';
+ data[ii] = g_ascii_isprint(bin[ii]) ? bin[ii] : '.';
break;
}
}
diff --git a/ui/qt/follow_stream_dialog.cpp b/ui/qt/follow_stream_dialog.cpp
index a747b62812..0dc89d8c11 100644
--- a/ui/qt/follow_stream_dialog.cpp
+++ b/ui/qt/follow_stream_dialog.cpp
@@ -609,7 +609,7 @@ static inline void sanitize_buffer(char *buffer, size_t nchars) {
for (size_t i = 0; i < nchars; i++) {
if (buffer[i] == '\n' || buffer[i] == '\r' || buffer[i] == '\t')
continue;
- if (! isprint((guchar)buffer[i])) {
+ if (! g_ascii_isprint((guchar)buffer[i])) {
buffer[i] = '.';
}
}
@@ -690,7 +690,7 @@ FollowStreamDialog::follow_show(char *buffer, size_t nchars, gboolean is_from_se
/* Now dump bytes as text */
for (i = 0; i < 16 && current_pos + i < nchars; i++) {
*cur++ =
- (isprint((guchar)buffer[current_pos + i]) ?
+ (g_ascii_isprint((guchar)buffer[current_pos + i]) ?
buffer[current_pos + i] : '.' );
if (i == 7) {
*cur++ = ' ';
diff --git a/wiretap/k12.c b/wiretap/k12.c
index 04245c52bc..cd1bbe6104 100644
--- a/wiretap/k12.c
+++ b/wiretap/k12.c
@@ -128,7 +128,7 @@ void k12_ascii_dump(guint level, guint8 *buf, guint32 len, guint32 buf_offset) {
if (debug_level < level) return;
for (i = buf_offset; i < len; i++) {
- if (isprint(buf[i]) || buf[i] == '\n' || buf[i] == '\t')
+ if (g_ascii_isprint(buf[i]) || buf[i] == '\n' || buf[i] == '\t')
putc(buf[i], dbg_out);
else if (buf[i] == '\0')
fprintf(dbg_out, "(NUL)\n");
diff --git a/wsutil/str_util.c b/wsutil/str_util.c
index 72783f3b91..898ae63171 100644
--- a/wsutil/str_util.c
+++ b/wsutil/str_util.c
@@ -85,7 +85,7 @@ isprint_string(const gchar *str)
/* Loop until we reach the end of the string (a null) */
for(pos = 0; str[pos] != '\0'; pos++){
- if(!isprint(str[pos])){
+ if(!g_ascii_isprint(str[pos])){
/* The string contains a non-printable character */
return FALSE;
}