]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-pflog.c
NDOize AH, BEEP and DTP decoders
[tcpdump] / print-pflog.c
index 8a3b66aaf41402038a2ec91c71c6b47e89ec302c..f5f8d424d208d2abcce3f19f8c5fc1138cad8d9f 100644 (file)
  * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
  */
 
-#ifndef lint
-static const char rcsid[] _U_ =
-    "@(#) $Header: /tcpdump/master/tcpdump/print-pflog.c,v 1.16 2007-09-12 19:36:18 guy Exp $ (LBL)";
-#endif
-
 #ifdef HAVE_CONFIG_H
 #include "config.h"
 #endif
@@ -44,7 +39,8 @@ static const char rcsid[] _U_ =
 
 #include "extract.h"
 #include "interface.h"
-#include "addrtoname.h"
+
+static const char tstr[] = "[|pflog]";
 
 static const struct tok pf_reasons[] = {
        { 0,    "0(match)" },
@@ -120,7 +116,7 @@ pflog_if_print(const struct pcap_pkthdr *h, register const u_char *p)
 
        /* check length */
        if (caplen < sizeof(u_int8_t)) {
-               printf("[|pflog]");
+               printf("%s", tstr);
                return (caplen);
        }
 
@@ -133,7 +129,7 @@ pflog_if_print(const struct pcap_pkthdr *h, register const u_char *p)
        hdrlen = BPF_WORDALIGN(hdr->length);
 
        if (caplen < hdrlen) {
-               printf("[|pflog]");
+               printf("%s", tstr);
                return (hdrlen);        /* XXX: true? */
        }
 
@@ -142,7 +138,7 @@ pflog_if_print(const struct pcap_pkthdr *h, register const u_char *p)
        TCHECK(*hdr);
        if (eflag)
                pflog_print(hdr);
-       
+
        /* skip to the real packet */
        af = hdr->af;
        length -= hdrlen;
@@ -173,10 +169,10 @@ pflog_if_print(const struct pcap_pkthdr *h, register const u_char *p)
                if (!suppress_default_print)
                        default_print(p, caplen);
        }
-       
+
        return (hdrlen);
 trunc:
-       printf("[|pflog]");
+       printf("%s", tstr);
        return (hdrlen);
 }