Wireshark-commits: [Wireshark-commits] master-2.0 b2fcce6: Handle the new LINKTYPE_CAN_SOCKETCAN_HO
From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Fri, 19 Aug 2016 02:44:26 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=b2fcce6eb0a706eca806782b533de8324fd213e2
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master-2.0
Repository: wireshark

Commits:

b2fcce6 by Guy Harris (guy@xxxxxxxxxxxx):

    Handle the new LINKTYPE_CAN_SOCKETCAN_HOSTENDIAN.
    
    Unfortunately, only one libpcap code path puts the CAN ID in the
    SocketCAN header in network byte order; the others leave it in host byte
    order.  Therefore, a new LINKTYPE_/DLT_ value was introduced, and
    libpcap was changed to use that for the cases where the CAN ID is in
    host byte order.  Support them both.
    
    This means we need to, when reading pcap and pcapng files, fix up the
    CAN ID if the host that wrote the file has a different byte order from
    ours (as libpcap also now does).  This includes Linux "cooked" captures,
    which can include CAN packets.
    
    Change-Id: If46b66df879abfba0cabef64a0a3e3e3d02f19ec
    Reviewed-on: https://code.wireshark.org/review/17157
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    

Actions performed:

    from  96f9bbc   SEL Protocol - Fix 'Fast Meter Config' sub-tree addition typo & 'if (tree)' usage
    adds  b2fcce6   Handle the new LINKTYPE_CAN_SOCKETCAN_HOSTENDIAN.


Summary of changes:
 epan/dissectors/packet-socketcan.c |   42 +++++++++++---
 wiretap/pcap-common.c              |  107 +++++++++++++++++++++++++++++++++++-
 wiretap/wtap.c                     |    7 ++-
 wiretap/wtap.h                     |    3 +-
 4 files changed, 146 insertions(+), 13 deletions(-)