Commit Graph

11 Commits

Author SHA1 Message Date
Guy Harris 961e0cdfa2 Convert some "col_add_str()" calls to "col_set_str()".
svn path=/trunk/; revision=4592
2002-01-21 23:35:32 +00:00
Guy Harris ee5ca25d31 Include files from the "epan" directory and subdirectories thereof with
"epan/..." pathnames, so as to avoid collisions with header files in any
of the directories in which we look (e.g., "proto.h", as some other
package has its own "proto.h" file which it installs in the top-level
include directory).

Don't add "-I" flags to search "epan", as that's no longer necessary
(and we want includes of "epan" headers to fail if the "epan/" is left
out, so that we don't re-introduce includes lacking "epan/").

svn path=/trunk/; revision=4586
2002-01-21 07:37:49 +00:00
Guy Harris 92915713d3 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.

svn path=/trunk/; revision=4578
2002-01-20 22:12:39 +00:00
Guy Harris 13fe7dd35c Put one NDMP top-level protocol tree item in for every NDMP PDU (which
means *no* top-level tree item if we don't find any NDMP PDUs).

Check for desegmentation before checking anything else, so that we don't
fail to desegment merely because we have, for example, only the record
marker in the first TCP segment (I've seen a capture where the first TCP
segment of an NDMP message has only the record marker).

svn path=/trunk/; revision=4572
2002-01-18 22:37:56 +00:00
Guy Harris 8e18ef8bbc Make the default for NDMP desegmentation TRUE, as is the case for most
other protocols running atop TCP (and which should be the case for *all*
of them, if it isn't so already; there's already a flag to control
desegmentation in TCP, and it should, by default, be possible to turn
that on and get desegmentation of all protocols).

svn path=/trunk/; revision=4568
2002-01-18 21:16:39 +00:00
Guy Harris 86d348aed1 Fix some preferences to eliminate the extra copy of the protocol name at
the beginning, and to use underscores rather than periods where the
preference's name really isn't part of a hierarchical namespace.

Use "%u" rather than "%d" to print unsigned quantities.

svn path=/trunk/; revision=4543
2002-01-15 10:01:21 +00:00
Guy Harris 8289dd46d2 From Ronnie Sahlberg: use size from encapsulation instead of how many
bytes were dissected since there can be padding bytes after the ndmp pdu
and to the end of what size said it would be, and some other cleanups.

svn path=/trunk/; revision=4486
2002-01-05 20:08:47 +00:00
Guy Harris ba74898e8c Additional sanity checks, from Ronnie Sahlberg.
svn path=/trunk/; revision=4485
2002-01-05 20:05:53 +00:00
Guy Harris 3ed03cadf6 Further updates from Ronnie Sahlberg.
svn path=/trunk/; revision=4483
2002-01-04 23:53:40 +00:00
Guy Harris 5b288fc0da Most of NDMP, from Ronnie Sahlberg.
svn path=/trunk/; revision=4479
2002-01-04 19:55:03 +00:00
Guy Harris 6f0d79c0d7 From Ronnie Sahlberg: initial NDMPv3 support, and an update to his
e-mail address.

svn path=/trunk/; revision=4444
2001-12-23 21:36:58 +00:00