Wireshark-commits: [Wireshark-commits] rev 47924: / /trunk/plugins/asn1/: packet-asn1.c /trunk/epan
Date: Wed, 27 Feb 2013 22:43:56 GMT
http://anonsvn.wireshark.org/viewvc/viewvc.cgi?view=rev&revision=47924

User: guy
Date: 2013/02/27 02:43 PM

Log:
 Move show_exception() and show_reported_bounds_error() to
 epan/show_exception.c, as it's used outside
 epan/dissectors/packet-frame.c.  Update their callers to include
 <epan/show_exception.h> to get their declaration.
 
 Add a CATCH_NONFATAL_ERRORS macro that catches all exceptions that, if
 there's more stuff in the packet to dissect after the dissector call
 that threw the exception, doesn't mean you shouldn't go ahead and
 dissect that stuff.  Use it in all those cases, including ones where
 BoundsError was inappropriately being caught (you want those passed up
 to the top level, so that the packet is reported as having been cut
 short in the capture process).
 
 Add a CATCH_BOUNDS_ERRORS macro that catches all exceptions that
 correspond to running past the end of the data for a tvbuff; use it
 rather than explicitly catching those exceptions individually, and
 rather than just catching all exceptions (the only place that
 DissectorError should be caught, for example, is at the top level, so
 dissector bugs show up in the protocol tree).
 
 Don't catch and then immediately rethrow exceptions without doing
 anything else; just let the exceptions go up to the final catcher.
 
 Use show_exception() to report non-fatal errors, rather than doing it
 yourself.
  
 If a dissector is called from Lua, catch all non-fatal errors and use
 show_exception() to report them rather than catching only
 ReportedBoundsError and adding a proto_malformed item.
 
 Don't catch exceptions when constructing a trailer tvbuff in
 packet-ieee8023.c - just construct it after the payload has been
 dissected, and let whatever exceptions that throws be handled at the top
 level.
 
 Avoid some TRY/CATCH/ENDTRY cases by using checks such as
 tvb_bytes_exist() before even looking in the tvbuff.

Directory: /trunk/plugins/asn1/
  Changes    Path             Action
  +0 -3      packet-asn1.c    Modified

Directory: /trunk/epan/dissectors/
  Changes    Path                       Action
  +10 -13    packet-bgp.c               Modified
  +3 -8      packet-cisco-wids.c        Modified
  +29 -21    packet-dcerpc.c            Modified
  +1 -1      packet-eth.c               Modified
  +12 -30    packet-ethertype.c         Modified
  +5 -121    packet-frame.c             Modified
  +0 -19     packet-frame.h             Modified
  +22 -12    packet-gssapi.c            Modified
  +14 -12    packet-h223.c              Modified
  +1 -6      packet-ieee80211.c         Modified


(44 files not shown)