]> The Tcpdump Group git mirrors - tcpdump/blobdiff - print-ppp.c
PPP: Check if there is some data to hexdump
[tcpdump] / print-ppp.c
index aba243ddb6f252251be5649fa5decdeccf0b4e4a..38505355182ca15067ea3e0b6ac76a8345cc6ece 100644 (file)
@@ -1131,7 +1131,7 @@ print_ipcp_config_options(netdissect_options *ndo,
                        print_unknown_data(ndo, p + 2, "\n\t    ", len - 2);
                break;
        }
-       if (ndo->ndo_vflag > 1)
+       if (ndo->ndo_vflag > 1 && ND_TTEST_LEN(p + 2, len - 2))
                print_unknown_data(ndo, p + 2, "\n\t    ", len - 2); /* exclude TLV header */
        return len;