- if (sport == TELNET_PORT || dport == TELNET_PORT) {
- if (!qflag && vflag)
- telnet_print(bp, length);
- } else if (sport == BGP_PORT || dport == BGP_PORT)
- bgp_print(bp, length);
- else if (sport == PPTP_PORT || dport == PPTP_PORT)
- pptp_print(bp);
-#ifdef TCPDUMP_DO_SMB
- else if (sport == NETBIOS_SSN_PORT || dport == NETBIOS_SSN_PORT)
- nbt_tcp_print(bp, length);
- else if (sport == SMB_PORT || dport == SMB_PORT)
- smb_tcp_print(bp, length);
+ if (IS_SRC_OR_DST_PORT(TELNET_PORT)) {
+ telnet_print(ndo, bp, length);
+ } else if (IS_SRC_OR_DST_PORT(SMTP_PORT)) {
+ ND_PRINT((ndo, ": "));
+ smtp_print(ndo, bp, length);
+ } else if (IS_SRC_OR_DST_PORT(WHOIS_PORT)) {
+ ND_PRINT((ndo, ": "));
+ txtproto_print(ndo, bp, length, "whois", NULL, 0); /* RFC 3912 */
+ } else if (IS_SRC_OR_DST_PORT(BGP_PORT))
+ bgp_print(ndo, bp, length);
+ else if (IS_SRC_OR_DST_PORT(PPTP_PORT))
+ pptp_print(ndo, bp);
+ else if (IS_SRC_OR_DST_PORT(REDIS_PORT))
+ resp_print(ndo, bp, length);
+#ifdef ENABLE_SMB
+ else if (IS_SRC_OR_DST_PORT(NETBIOS_SSN_PORT))
+ nbt_tcp_print(ndo, bp, length);
+ else if (IS_SRC_OR_DST_PORT(SMB_PORT))
+ smb_tcp_print(ndo, bp, length);