X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/ee68aa36460d7efeca48747f33b7f2adc0900bfb..b5068d5380c73e02bc35a96f641cad18d9b03f3d:/print-snmp.c diff --git a/print-snmp.c b/print-snmp.c index aa2974cc..03e5c3b4 100644 --- a/print-snmp.c +++ b/print-snmp.c @@ -71,6 +71,8 @@ #include #endif +#include "netdissect-ctype.h" + #include "netdissect.h" #include "extract.h" @@ -197,7 +199,7 @@ static const char *ErrorStatus[] = { #define DECODE_ErrorStatus(e) \ ( e >= 0 && (size_t)e < sizeof(ErrorStatus)/sizeof(ErrorStatus[0]) \ ? ErrorStatus[e] \ - : (nd_snprintf(errbuf, sizeof(errbuf), "err=%u", e), errbuf)) + : (snprintf(errbuf, sizeof(errbuf), "err=%u", e), errbuf)) /* * generic-trap values in the SNMP Trap-PDU @@ -215,7 +217,7 @@ static const char *GenericTrap[] = { #define DECODE_GenericTrap(t) \ ( t >= 0 && (size_t)t < sizeof(GenericTrap)/sizeof(GenericTrap[0]) \ ? GenericTrap[t] \ - : (nd_snprintf(buf, sizeof(buf), "gt=%d", t), buf)) + : (snprintf(buf, sizeof(buf), "gt=%d", t), buf)) /* * ASN.1 type class table @@ -700,7 +702,7 @@ asn1_print_string(netdissect_options *ndo, struct be *elem) p = elem->data.str; ND_TCHECK_LEN(p, asnlen); for (i = asnlen; printable && i != 0; p++, i--) - printable = ND_ISPRINT(GET_U_1(p)); + printable = ND_ASCII_ISPRINT(GET_U_1(p)); p = elem->data.str; if (printable) { ND_PRINT("\"");