summaryrefslogtreecommitdiff
path: root/print-ascii.c
diff options
context:
space:
mode:
authorguy <guy>2004-07-21 22:00:10 +0000
committerguy <guy>2004-07-21 22:00:10 +0000
commit03862177ea6a26f0792f47e736f2457b4fc7c898 (patch)
treebd078e8a51485c6489689458714bb84ae2f86121 /print-ascii.c
parent608bcf8fa928d0f5d75d525359fcb6425da7d041 (diff)
downloadtcpdump-03862177ea6a26f0792f47e736f2457b4fc7c898.tar.gz
The first argument to "ascii_print_with_offset()", "ascii_print()",
"hex_print_with_offset()", and "hex_print()" is a string used as a tag; make it a "const char *", not a "const u_char *". Copy the declaration of "strsep()" from "interface.h" to "netdissect.h", and get rid of the include of "interface.h" from "print-esp.c", as it includes "netdissect.h". Update the "ND_TTEST2()" macro to do the same overflow checks that "TTEST2()" now does.
Diffstat (limited to 'print-ascii.c')
-rw-r--r--print-ascii.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/print-ascii.c b/print-ascii.c
index 78297c44..1b894850 100644
--- a/print-ascii.c
+++ b/print-ascii.c
@@ -42,7 +42,7 @@
#ifndef lint
static const char rcsid[] _U_ =
- "@(#) $Header: /tcpdump/master/tcpdump/print-ascii.c,v 1.15 2003-12-29 11:05:10 hannes Exp $";
+ "@(#) $Header: /tcpdump/master/tcpdump/print-ascii.c,v 1.16 2004-07-21 22:00:10 guy Exp $";
#endif
#include <tcpdump-stdinc.h>
#include <stdio.h>
@@ -57,7 +57,7 @@ static const char rcsid[] _U_ =
(HEXDUMP_HEXSTUFF_PER_SHORT * HEXDUMP_SHORTS_PER_LINE)
void
-ascii_print_with_offset(register const u_char *ident, register const u_char *cp, register u_int length,
+ascii_print_with_offset(register const char *ident, register const u_char *cp, register u_int length,
register u_int oset)
{
register u_int i;
@@ -126,7 +126,7 @@ ascii_print_with_offset(register const u_char *ident, register const u_char *cp,
}
void
-ascii_print(register const u_char *ident, register const u_char *cp, register u_int length)
+ascii_print(register const char *ident, register const u_char *cp, register u_int length)
{
ascii_print_with_offset(ident, cp, length, 0);
}
@@ -135,7 +135,7 @@ ascii_print(register const u_char *ident, register const u_char *cp, register u_
* telnet_print() wants this. It is essentially default_print_unaligned()
*/
void
-hex_print_with_offset(register const u_char *ident, register const u_char *cp, register u_int length,
+hex_print_with_offset(register const char *ident, register const u_char *cp, register u_int length,
register u_int oset)
{
register u_int i, s;
@@ -162,7 +162,7 @@ hex_print_with_offset(register const u_char *ident, register const u_char *cp, r
* just for completeness
*/
void
-hex_print(register const u_char *ident, register const u_char *cp, register u_int length)
+hex_print(register const char *ident, register const u_char *cp, register u_int length)
{
hex_print_with_offset(ident, cp, length, 0);
}