Wireshark-commits: [Wireshark-commits] master a4c8ebc: Don't do any Decode As stuff for dissector t
From: Wireshark code review <code-review-do-not-reply@xxxxxxxxxxxxx>
Date: Wed, 31 Aug 2016 00:08:22 +0000 (UTC)
URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=a4c8ebc18b71200d7a6245e386e97a9d14c5dbdb
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark

Commits:

a4c8ebc by Guy Harris (guy@xxxxxxxxxxxx):

    Don't do any Decode As stuff for dissector tables not used with Decode As.
    
    Have all dissector tables have a "supports Decode As" flag, which
    defaults to FALSE, and which is set to TRUE if a register_decode_as()
    refers to it.
    
    When adding a dissector to a dissector table with a given key, only add
    it for Decode As if the dissector table supports it.
    
    For non-FT_STRING dissector tables, always check for multiple entries
    for the same protocol with different dissectors, and report an error if
    we found them.
    
    This means there's no need for the creator of a dissector table to
    specify whether duplicates of that sort should be allowed - we always do
    the check when registering something for "Decode As" (in a non-FT_STRING
    dissector table), and just don't bother registering anything for "Decode
    As" if the dissector table doesn't support "Decode As", so there's no
    check done for those dissector tables.
    
    Change-Id: I4a1fdea3bddc2af27a65cfbca23edc99b26c0eed
    Reviewed-on: https://code.wireshark.org/review/17402
    Petri-Dish: Guy Harris <guy@xxxxxxxxxxxx>
    Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
    

Actions performed:

    from  1dbd221   RTPS: Allowing duplicates in the rtps.type_name table
    adds  a4c8ebc   Don't do any Decode As stuff for dissector tables not used with Decode As.


Summary of changes:
 debian/libwireshark0.symbols                       |    2 +-
 doc/README.dissector                               |    2 +-
 epan/decode_as.c                                   |   16 +---
 .../asn1/ansi_map/packet-ansi_map-template.c       |    6 +-
 .../asn1/ansi_tcap/packet-ansi_tcap-template.c     |    2 +-
 epan/dissectors/asn1/camel/packet-camel-template.c |    6 +-
 epan/dissectors/asn1/cmip/packet-cmip-template.c   |    2 +-
 epan/dissectors/asn1/dop/packet-dop-template.c     |    2 +-
 .../asn1/gsm_map/packet-gsm_map-template.c         |   10 +--
 epan/dissectors/asn1/h225/packet-h225-template.c   |   10 +--
 epan/dissectors/asn1/h245/packet-h245-template.c   |    8 +-
 epan/dissectors/asn1/h248/packet-h248-template.c   |    2 +-
 epan/dissectors/asn1/h450/packet-h450-template.c   |   12 +--
 epan/dissectors/asn1/hnbap/packet-hnbap-template.c |   10 +--
 epan/dissectors/asn1/lcsap/packet-lcsap-template.c |   10 +--
 epan/dissectors/asn1/ldap/packet-ldap-template.c   |    2 +-
 epan/dissectors/asn1/lppa/packet-lppa-template.c   |    8 +-
 epan/dissectors/asn1/m3ap/packet-m3ap-template.c   |   10 +--
 epan/dissectors/asn1/nbap/packet-nbap-template.c   |   10 +--
 epan/dissectors/asn1/p1/packet-p1-template.c       |    6 +-
 epan/dissectors/asn1/pcap/packet-pcap-template.c   |   16 ++--
 epan/dissectors/asn1/q932/packet-q932-template.c   |   18 ++---
 epan/dissectors/asn1/qsig/packet-qsig-template.c   |    2 +-
 epan/dissectors/asn1/ranap/packet-ranap-template.c |   20 ++---
 epan/dissectors/asn1/rnsap/packet-rnsap-template.c |   10 +--
 epan/dissectors/asn1/ros/packet-ros-template.c     |    2 +-
 epan/dissectors/asn1/rtse/packet-rtse-template.c   |    2 +-
 epan/dissectors/asn1/rua/packet-rua-template.c     |   10 +--
 epan/dissectors/asn1/s1ap/packet-s1ap-template.c   |   14 ++--
 epan/dissectors/asn1/sabp/packet-sabp-template.c   |   10 +--
 .../asn1/sbc-ap/packet-sbc-ap-template.c           |   10 +--
 epan/dissectors/asn1/snmp/packet-snmp-template.c   |    2 +-
 epan/dissectors/asn1/t124/packet-t124-template.c   |    4 +-
 epan/dissectors/asn1/x2ap/packet-x2ap-template.c   |   10 +--
 epan/dissectors/file-file.c                        |    2 +-
 epan/dissectors/packet-ansi_637.c                  |    2 +-
 epan/dissectors/packet-ansi_a.c                    |    6 +-
 epan/dissectors/packet-ansi_map.c                  |    6 +-
 epan/dissectors/packet-ansi_tcap.c                 |    2 +-
 epan/dissectors/packet-arcnet.c                    |    2 +-
 epan/dissectors/packet-aruba-erm.c                 |    2 +-
 epan/dissectors/packet-atalk.c                     |    2 +-
 epan/dissectors/packet-atm.c                       |    4 +-
 epan/dissectors/packet-ax25.c                      |    2 +-
 epan/dissectors/packet-bacapp.c                    |    2 +-
 epan/dissectors/packet-bacnet.c                    |    2 +-
 epan/dissectors/packet-bctp.c                      |    2 +-
 epan/dissectors/packet-ber.c                       |    4 +-
 epan/dissectors/packet-bitcoin.c                   |    2 +-
 epan/dissectors/packet-bluecom.c                   |    2 +-
 epan/dissectors/packet-bluetooth.c                 |    6 +-
 epan/dissectors/packet-bssap.c                     |    4 +-
 epan/dissectors/packet-btatt.c                     |    2 +-
 epan/dissectors/packet-btbredr_rf.c                |   14 ++--
 epan/dissectors/packet-bthci_cmd.c                 |    6 +-
 epan/dissectors/packet-btl2cap.c                   |    4 +-
 epan/dissectors/packet-btrfcomm.c                  |    2 +-
 epan/dissectors/packet-bvlc.c                      |    2 +-
 epan/dissectors/packet-c15ch.c                     |    8 +-
 epan/dissectors/packet-camel.c                     |    6 +-
 epan/dissectors/packet-ccsds.c                     |    2 +-
 epan/dissectors/packet-chdlc.c                     |    2 +-
 epan/dissectors/packet-cip.c                       |    4 +-
 epan/dissectors/packet-cmip.c                      |    2 +-
 epan/dissectors/packet-cnip.c                      |    2 +-
 epan/dissectors/packet-dccp.c                      |    2 +-
 epan/dissectors/packet-dcerpc.c                    |    2 +-
 epan/dissectors/packet-dcp-etsi.c                  |    6 +-
 epan/dissectors/packet-diameter.c                  |    8 +-
 epan/dissectors/packet-dmx.c                       |    2 +-
 epan/dissectors/packet-dns.c                       |    2 +-
 epan/dissectors/packet-dof.c                       |   16 ++--
 epan/dissectors/packet-dop.c                       |    2 +-
 epan/dissectors/packet-dtls.c                      |    2 +-
 epan/dissectors/packet-dvbci.c                     |    2 +-
 epan/dissectors/packet-eapol.c                     |    2 +-
 epan/dissectors/packet-ecp.c                       |    2 +-
 epan/dissectors/packet-enc.c                       |    2 +-
 epan/dissectors/packet-enip.c                      |    6 +-
 epan/dissectors/packet-epl.c                       |    2 +-
 epan/dissectors/packet-erf.c                       |    2 +-
 epan/dissectors/packet-ethertype.c                 |    2 +-
 epan/dissectors/packet-fc.c                        |    2 +-
 epan/dissectors/packet-fcct.c                      |    2 +-
 epan/dissectors/packet-flexray.c                   |    2 +-
 epan/dissectors/packet-flip.c                      |    2 +-
 epan/dissectors/packet-fr.c                        |    4 +-
 epan/dissectors/packet-frame.c                     |    4 +-
 epan/dissectors/packet-gfp.c                       |    2 +-
 epan/dissectors/packet-gprs-llc.c                  |    2 +-
 epan/dissectors/packet-gre.c                       |    2 +-
 epan/dissectors/packet-gsm_a_dtap.c                |    2 +-
 epan/dissectors/packet-gsm_a_gm.c                  |    2 +-
 epan/dissectors/packet-gsm_ipa.c                   |    2 +-
 epan/dissectors/packet-gsm_map.c                   |   10 +--
... 123 lines suppressed ...