Commit Graph

24 Commits

Author SHA1 Message Date
Guy Harris 8c8c91d521 Fix formats for "sizeof" so that "sizeof" values get displayed correctly
if they're "int"s or "long"s.

Get rid of the unused PGM_xxx_SZ variables.

svn path=/trunk/; revision=10357
2004-03-09 20:23:20 +00:00
Guy Harris c7a7cd5e0f Add some checks for valid option lengths, and for the first option being
a length option.

Break out of the option processing loop if we see an option with the
"end" bit set.

svn path=/trunk/; revision=10353
2004-03-09 06:46:03 +00:00
Guy Harris 29bc812334 Add an hf[] entry for the OPT_FRAG_OFF field of the OPT_FRAGMENT option
(the hf_ variable for it existed, but there was no hf[] entry, so it
didn't get initialized).

svn path=/trunk/; revision=9362
2003-12-19 22:46:16 +00:00
Guy Harris afd3103ba2 Don't include <epan/conversation.h> if you don't need it.
svn path=/trunk/; revision=8361
2003-09-03 20:58:09 +00:00
Gerald Combs 588b90738a From Todd Montgomery: Bring PGM up to date with RFC 3208:
- checksum checks for all packets (like UDP, IP, TCP, etc.)
                - this includes adding an option to turn off checking
                  it in the preferences menu (like TCP does).
        - POLL packets
        - POLR packets
        - added PGM options:
                - OPT_FRAGMENT
                - OPT_REDIRECT
                - OPT_NAK_BO_IVL
                - OPT_NAK_BO_RNG
        - fixed a minor offset error in SPMs

svn path=/trunk/; revision=7349
2003-03-12 04:04:15 +00:00
Jörg Mayer 7c4176d868 Removed trailing whitespaces from .h and .c files using the
winapi_cleanup tool written by Patrik Stridvall for the wine
project.

svn path=/trunk/; revision=6117
2002-08-28 21:04:11 +00:00
Guy Harris 968a88bfdc We don't use anything from <sys/socket.h>, so we don't need to include
it.

svn path=/trunk/; revision=5940
2002-08-03 19:50:44 +00:00
Jörg Mayer 173fe5aef4 Replace the types from sys/types.h and netinet/in.h by their glib.h
equivalents for the toplevel directory. The removal of winsock2.h will
hopefully not cause any problems under MSVC++, as those files using
struct timeval still include wtap.h, which still includes winsock2.h.

svn path=/trunk/; revision=5932
2002-08-02 23:36:07 +00:00
Guy Harris 9a80f0a521 Removal (or, at least, #ifdeffing out) of unused variables and
functions, from David Frascone.

svn path=/trunk/; revision=5288
2002-04-29 08:20:18 +00:00
Guy Harris db31932941 From Joerg Mayer:
Declares some variables static.

	Creates a new include file packet-rsvp.h, and make use of it
	(change some extern decls to #inlcude).

	Move the file packet-pgm.h into packet-pgm.c as it is not used
	by anything outside packet-pgm.c.

svn path=/trunk/; revision=5162
2002-04-14 23:04:04 +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 a45d3d3bfe Fix some problems in protocol preferences blurbs.
svn path=/trunk/; revision=4582
2002-01-20 23:25:55 +00:00
Guy Harris 23319ff023 Move the pointer to the "column_info" structure in the "frame_data"
structure to the "packet_info" structure; only stuff that's permanently
stored with each frame should be in the "frame_data" structure, and the
"column_info" structure is not guaranteed to hold the column values for
that frame at all times - it was only in the "frame_data" structure so
that it could be passed to dissectors, and, as all dissectors are now
passed a pointer to a "packet_info" structure, it could just as well be
put in the "packet_info" structure.

That saves memory, by shrinking the "frame_data" structure (there's one
of those per frame), and also lets us clean up the code a bit.

svn path=/trunk/; revision=4370
2001-12-10 00:26:21 +00:00
Guy Harris 75cc056222 Attach a descriptive name field type and base to dissector tables; that
specifies how the selector values used as keys in those tables are to be
displayed, and the title to use when displaying the table.

Use that information in the code to display the initial and current
entries of various dissector tables.

Have the dissector for BACnet APDUs register itself by name, and have
the BACnet NPDU dissector call it iff the BAC_CONTROL_NET bit isn't set,
rather than doing it with a dissector table.

svn path=/trunk/; revision=4358
2001-12-08 06:41:48 +00:00
Guy Harris bced8711f6 Make "dissector_add()", "dissector_delete()", and "dissector_change()"
take a dissector handle as an argument, rather than a pointer to a
dissector function and a protocol ID.  Associate dissector handles with
dissector table entries.

svn path=/trunk/; revision=4308
2001-12-03 04:00:26 +00:00
Ed Warnicke 34dbc86e65 Moved from using dissect_data to using call_dissector()
svn path=/trunk/; revision=4264
2001-11-25 22:51:14 +00:00
Guy Harris 60fe401dc7 Get rid of some unused variables.
svn path=/trunk/; revision=4241
2001-11-21 02:01:06 +00:00
Guy Harris 57091e1abb Update from Steve Dickson to add support for UDP encapsulation of PGM
packets.

svn path=/trunk/; revision=3831
2001-08-06 19:05:14 +00:00
Guy Harris 131228b0b1 Updates from Steve Dickson.
svn path=/trunk/; revision=3812
2001-08-02 17:05:00 +00:00
Guy Harris 681f73adb7 There is really no need to have the BGP dissector and the LDP dissector
have two independent "value_string" tables mapping RFC 1700 address
family numbers to names, nor is there any need to have the BGP dissector
and the PIM dissector have two independent sets of #defines for RFC 1700
address family numbers; put a single "value_string" table in "afn.c" and
put a declaration of it, and #defines for the address family numbers,
into "afn.h", and have the dissectors use that.

Move the #define for PGM into "ipproto.h", and add an entry for it in
the "value_string" table in "ipproto.c".

Have the PGM dissector use the standard Ethereal mechanisms for
resolving addresses, and have it use "value_string" tables for mapping
option types, the OPX bits, and packet types to strings.  Use
"bytes_to_str()" to turn byte arrays into strings of hex digits.  Pass
the packet type string to "dissect_pgmopts()" as an argument, rather
than making it a global.  Don't use "proto_tree_add_XXX_format" routines
if you can possibly just use "proto_tree_add_XXX"; give various fields
the correct radix and type, and VALS() strings if necessary, to make
that happen (and to make filtering on them more pleasant).  Put the
type, length, and total length of the options into the protocol tree as
separate fields.  Don't have separate type, length, and OPX fields for
every type of option; one field will suffice.  Don't format a string
with "sprintf()" and then pass that string to "col_add_fstr()" with a
format of "%s" and the string as an argument - "col_add_fstr()" can
format strings itself (that's what the "f" stands for).  Don't byte-swap
and then un-byte-swap IPv4 address fields in the header, just leave them
network byte order to start with.  Use the correct fields for
"proto_tree_add_XXX", rather than using the same field multiple times.
Quit early if an address family identifier isn't AFNUM_INET, as that
means the structure we use to dissect the header doesn't match the
actual header.

svn path=/trunk/; revision=3761
2001-07-21 10:27:13 +00:00
Guy Harris 45510255a7 "inline" is an extension to C, not a standard part of C; don't declare
functions as "inline", use G_INLINE_FUNC (<glib.h> declares it
appropriately).

Put in a URL for the current PGM draft.

svn path=/trunk/; revision=3757
2001-07-20 23:21:33 +00:00
Uwe Girlich 3d152ef40a The type pgm_t is also defined in /usr/include/sys/immu.h on SINIX-N systems.
So I renamed it to pgm_type to remove the name-clash.

svn path=/trunk/; revision=3715
2001-07-13 11:42:44 +00:00
Guy Harris 9c0d2087dc Pragmatic General Multicast isn't RFC 2705.
svn path=/trunk/; revision=3704
2001-07-12 21:48:46 +00:00
Guy Harris 23b15f991f PGM (Pragmatic General Multicast - RFC 2705) support, from Steve Dickson.
svn path=/trunk/; revision=3702
2001-07-12 20:16:29 +00:00