"@(#) Copyright (c) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997\n\
The Regents of the University of California. All rights reserved.\n";
static const char rcsid[] =
- "@(#) $Header: /tcpdump/master/tcpdump/tcpdump.c,v 1.138 1999-12-22 15:44:11 itojun Exp $ (LBL)";
+ "@(#) $Header: /tcpdump/master/tcpdump/tcpdump.c,v 1.143 2000-01-29 21:00:59 fenner Exp $ (LBL)";
#endif
/*
int xflag; /* print packet in hex */
int Xflag; /* print packet in ascii as well as hex */
-char *ahsecret = NULL; /* AH secret key */
char *espsecret = NULL; /* ESP secret key */
int packettype;
else
program_name = argv[0];
- if (abort_on_misalignment(ebuf) < 0)
+ if (abort_on_misalignment(ebuf, sizeof(ebuf)) < 0)
error("%s", ebuf);
#ifdef LIBSMI
opterr = 0;
while (
- (op = getopt(argc, argv, "ac:deE:fF:i:lnNm:Opqr:Rs:StT:vw:xXY")) != EOF)
+ (op = getopt(argc, argv, "ac:deE:fF:i:lm:nNOpqr:Rs:StT:vw:xXY")) != EOF)
switch (op) {
case 'a':
++aflag;
break;
-#if 0
- case 'A':
-#ifndef CRYPTO
- warning("crypto code not compiled in");
-#endif
- ahsecret = optarg;
- break;
-#endif
-
case 'c':
cnt = atoi(optarg);
if (cnt <= 0)
break;
case 'E':
-#ifndef CRYPTO
+#ifndef HAVE_LIBCRYPTO
warning("crypto code not compiled in");
#endif
espsecret = optarg;
break;
case 'X':
+ ++xflag;
++Xflag;
break;
/*
* By default, print the packet out in hex.
- *
- * (BTW, please don't send us patches to print the packet out in ascii)
*/
void
default_print(register const u_char *bp, register u_int length)
{
- default_print_unaligned(bp, length);
+ default_print_unaligned(bp, length);
}
__dead void