X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/546558eabd81cfc36a81a4df728fdfea0d83b41a..cbc7347ee977869f5d74820847e76bfd5ab8460d:/print-zephyr.c diff --git a/print-zephyr.c b/print-zephyr.c index 3edbeea4..b0f8cd31 100644 --- a/print-zephyr.c +++ b/print-zephyr.c @@ -1,7 +1,7 @@ /* * Decode and print Zephyr packets. * - * http://web.mit.edu/zephyr/doc/protocol + * https://web.mit.edu/zephyr/doc/protocol * * Copyright (c) 2001 Nickolai Zeldovich * All rights reserved. @@ -32,6 +32,8 @@ #include #include +#include "netdissect-ctype.h" + #include "netdissect.h" struct z_packet { @@ -119,7 +121,7 @@ z_triple(const char *class, const char *inst, const char *recipient) { if (!*recipient) recipient = "*"; - nd_snprintf(z_buf, sizeof(z_buf), "<%s,%s,%s>", class, inst, recipient); + snprintf(z_buf, sizeof(z_buf), "<%s,%s,%s>", class, inst, recipient); z_buf[sizeof(z_buf)-1] = '\0'; return z_buf; } @@ -134,7 +136,7 @@ str_to_lower(const char *string) zb_string = z_buf; while (*zb_string) { - *zb_string = tolower((unsigned char)(*zb_string)); + *zb_string = ND_ASCII_TOLOWER(*zb_string); zb_string++; } @@ -343,6 +345,6 @@ zephyr_print(netdissect_options *ndo, const u_char *cp, int length) return; trunc: - ND_PRINT(" [|zephyr] (%d)", length); + nd_print_trunc(ndo); return; }