]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-eap.c
Fix spaces
[tcpdump] / print-eap.c
index 55b04de8cf3ca6ea7cbb0e4307574e82461026ac..797224d645fbdfcd3101c1586f756727bc01d706 100644 (file)
 /* \summary: Extensible Authentication Protocol (EAP) printer */
 
 #ifdef HAVE_CONFIG_H
-#include "config.h"
+#include <config.h>
 #endif
 
-#include <netdissect-stdinc.h>
+#include "netdissect-stdinc.h"
 
 #include "netdissect.h"
 #include "extract.h"
@@ -156,6 +156,7 @@ eap_print(netdissect_options *ndo,
     u_int eap_type, tlen, type, subtype;
     int count=0, len;
 
+    ndo->ndo_protocol = "eap";
     tptr = cp;
     tlen = length;
     eap = (const struct eap_frame_t *)cp;
@@ -206,14 +207,14 @@ eap_print(netdissect_options *ndo,
             case EAP_TYPE_IDENTITY:
                 if (len - 5 > 0) {
                     ND_PRINT(", Identity: ");
-                    safeputs(ndo, tptr + 5, len - 5);
+                    (void)nd_printzp(ndo, tptr + 5, len - 5, NULL);
                 }
                 break;
 
             case EAP_TYPE_NOTIFICATION:
                 if (len - 5 > 0) {
                     ND_PRINT(", Notification: ");
-                    safeputs(ndo, tptr + 5, len - 5);
+                    (void)nd_printzp(ndo, tptr + 5, len - 5, NULL);
                 }
                 break;
 
@@ -295,11 +296,5 @@ eap_print(netdissect_options *ndo,
     return;
 
  trunc:
-    ND_PRINT("\n\t[|EAP]");
+    nd_print_trunc(ndo);
 }
-
-/*
- * Local Variables:
- * c-basic-offset: 4
- * End:
- */