From: Francois-Xavier Le Bail Date: Fri, 31 Jul 2020 10:19:51 +0000 (+0200) Subject: UDP: Harmonize some function calls X-Git-Tag: tcpdump-4.99-bp~305 X-Git-Url: https://git.tcpdump.org/tcpdump/commitdiff_plain/037f3e3e0c00c1d86e5245fb927e47179095b742 UDP: Harmonize some function calls Some calls use '(const u_char *)(up+1)'. Other calls use 'cp' (same value). Update the calls to only use 'cp'. (follow-up to ea0f25cc7765554e521bf7ea44d94f77500749f5) --- diff --git a/print-udp.c b/print-udp.c index 96d827cc..1c049418 100644 --- a/print-udp.c +++ b/print-udp.c @@ -682,7 +682,7 @@ udp_print(netdissect_options *ndo, const u_char *bp, u_int length, IS_SRC_OR_DST_PORT(RADIUS_NEW_ACCOUNTING_PORT) || IS_SRC_OR_DST_PORT(RADIUS_CISCO_COA_PORT) || IS_SRC_OR_DST_PORT(RADIUS_COA_PORT) ) - radius_print(ndo, (const u_char *)(up+1), length); + radius_print(ndo, cp, length); else if (dport == HSRP_PORT) hsrp_print(ndo, cp, length); else if (IS_SRC_OR_DST_PORT(LWRES_PORT)) @@ -695,12 +695,12 @@ udp_print(netdissect_options *ndo, const u_char *bp, u_int length, else if (IS_SRC_OR_DST_PORT(MPLS_LSP_PING_PORT)) lspping_print(ndo, cp, length); else if (sport == BCM_LI_PORT) - bcm_li_print(ndo, (const u_char *)(up+1), length); + bcm_li_print(ndo, cp, length); else if (dport == BFD_CONTROL_PORT || dport == BFD_MULTIHOP_PORT || dport == BFD_LAG_PORT || dport == BFD_ECHO_PORT ) - bfd_print(ndo, (const u_char *)(up+1), length, dport); + bfd_print(ndo, cp, length, dport); else if (IS_SRC_OR_DST_PORT(LMP_PORT)) lmp_print(ndo, cp, length); else if (IS_SRC_OR_DST_PORT(VQP_PORT))