X-Git-Url: https://git.tcpdump.org/tcpdump/blobdiff_plain/3824a6c0417a551961d1a1bf4f94f10eff736afc..refs/pull/482/head:/print-raw.c diff --git a/print-raw.c b/print-raw.c index 43dbff48..a89af5bf 100644 --- a/print-raw.c +++ b/print-raw.c @@ -19,35 +19,25 @@ * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. */ - #ifdef HAVE_CONFIG_H #include "config.h" #endif -#include - -#include -#include -#include +#include -#include "addrtoname.h" -#include "interface.h" +#include "netdissect.h" -#ifndef lint -static const char rcsid[] _U_ = - "@(#) $Header: /tcpdump/master/tcpdump/print-raw.c,v 1.40 2003-11-15 00:39:37 guy Exp $ (LBL)"; -#endif /* * The DLT_RAW packet has no header. It contains a raw IP packet. */ u_int -raw_if_print(const struct pcap_pkthdr *h, const u_char *p) +raw_if_print(netdissect_options *ndo, const struct pcap_pkthdr *h, const u_char *p) { - if (eflag) - printf("ip: "); + if (ndo->ndo_eflag) + ND_PRINT((ndo, "ip: ")); - ipN_print(p, h->len); + ipN_print(ndo, p, h->len); return (0); }