Ethereal-cvs: [Ethereal-cvs] cvs commit: ethereal packet-atalk.c packet-bacnet.c packet-dns.c
Note: This archive is from the project's previous web site, ethereal.com. This list is no longer active.
From: Guy Harris <guy@xxxxxxxxxxxxxxxxxxx>
Date: Sun, 20 Jan 2002 16:12:36 -0600 (CST)
guy 2002/01/20 16:12:36 CST Modified files: . packet-atalk.c packet-bacnet.c packet-dns.c packet-dvmrp.c packet-gmrp.c packet-gvrp.c packet-igmp.c packet-iscsi.c packet-isis-lsp.c packet-ldp.c packet-llc.c packet-m2pa.c packet-mount.c packet-mrdisc.c packet-msnip.c packet-mtp2.c packet-nbipx.c packet-nbns.c packet-ndmp.c packet-nfs.c packet-nisplus.c packet-pcnfsd.c packet-portmap.c packet-ppp.c packet-rpc.c packet-rtcp.c packet-rtsp.c packet-rx.c packet-sctp.c packet-smb-mailslot.c packet-smb-pipe.c packet-smb.c packet-sna.c packet-tcp.c packet-v120.c Log: Allow a length of -1 to be specified when adding FT_NONE and FT_PROTOCOL items to the protocol tree; it's interpreted as "the rest of the data in the tvbuff". This can be used if 1) the item covers the entire packet or the remaining payload in the packet or 2) the item's length won't be known until it's dissected, and will be then set with "proto_item_set_len()" - if an exception is thrown in the dissection, it means the item ran *past* the end of the tvbuff, so saying it runs to the end of the tvbuff is reasonable. Convert a number of "proto_tree_add_XXX()" calls using "tvb_length_remaining()", values derived from the result of "tvb_length()", or 0 (in the case of items whose length is unknown) to use -1 instead (using 0 means that if an exception is thrown, selecting the item highlights nothing; using -1 means it highlights all the data for that item that's available). In some places where "tvb_length()" or "tvb_length_remaining()" was used to determine how large a packet is, use "tvb_reported_length()" or "tvb_reported_length_remaining()", instead - the first two calls indicate how much captured data was in the packet, the latter two calls indicate how large the packet actually was (and the fact that using the latter could cause BoundsError exceptions to be thrown is a feature - if such an exception is thrown, the frame really *was* short, and it should be tagged as such). Replace some "proto_tree_add_XXX()" calls with equivalent "proto_tree_add_item()" calls. Fix some indentation. Revision Changes Path 1.61 +4 -6 ethereal/packet-atalk.c 1.9 +2 -2 ethereal/packet-bacnet.c 1.79 +3 -3 ethereal/packet-dns.c 1.6 +5 -5 ethereal/packet-dvmrp.c 1.4 +2 -2 ethereal/packet-gmrp.c 1.9 +3 -3 ethereal/packet-gvrp.c 1.16 +3 -3 ethereal/packet-igmp.c 1.21 +2 -2 ethereal/packet-iscsi.c 1.24 +7 -7 ethereal/packet-isis-lsp.c 1.24 +2 -3 ethereal/packet-ldp.c 1.94 +2 -2 ethereal/packet-llc.c 1.5 +6 -8 ethereal/packet-m2pa.c 1.29 +4 -4 ethereal/packet-mount.c 1.5 +2 -2 ethereal/packet-mrdisc.c 1.4 +5 -5 ethereal/packet-msnip.c 1.2 +3 -3 ethereal/packet-mtp2.c 1.45 +2 -2 ethereal/packet-nbipx.c 1.71 +7 -7 ethereal/packet-nbns.c 1.9 +5 -5 ethereal/packet-ndmp.c 1.64 +40 -47 ethereal/packet-nfs.c 1.10 +18 -19 ethereal/packet-nisplus.c 1.4 +4 -6 ethereal/packet-pcnfsd.c 1.33 +2 -2 ethereal/packet-portmap.c 1.86 +5 -6 ethereal/packet-ppp.c 1.84 +11 -13 ethereal/packet-rpc.c 1.29 +3 -3 ethereal/packet-rtcp.c 1.46 +3 -3 ethereal/packet-rtsp.c 1.30 +5 -5 ethereal/packet-rx.c 1.28 +21 -21 ethereal/packet-sctp.c 1.30 +2 -2 ethereal/packet-smb-mailslot.c 1.65 +8 -12 ethereal/packet-smb-pipe.c 1.196 +9 -9 ethereal/packet-smb.c 1.37 +3 -3 ethereal/packet-sna.c 1.127 +3 -5 ethereal/packet-tcp.c 1.23 +3 -3 ethereal/packet-v120.c
- Prev by Date: [Ethereal-cvs] cvs commit: ethereal/gtk capture_prefs.c gui_prefs.c nameres_prefs.c prefs_dlg.c prefs_dlg.h print_prefs.c
- Next by Date: [Ethereal-cvs] cvs commit: ethereal/doc README.developer
- Previous by thread: [Ethereal-cvs] cvs commit: ethereal/gtk capture_prefs.c gui_prefs.c nameres_prefs.c prefs_dlg.c prefs_dlg.h print_prefs.c
- Next by thread: [Ethereal-cvs] cvs commit: ethereal/doc README.developer
- Index(es):