Commit Graph

12 Commits

Author SHA1 Message Date
Guy Harris 5bfc21cf9e Clean up handling of missing functions.
With autotools, CMake, and nmake, if we have a function, #define
HAVE_{function_name_in_all_caps}, otherwise don't #define it.

If we provide our own version of a function in libwsutil, make sure we
have a header that declares it, and *ONLY* include that header if
HAVE_{function_name_in_all_caps} is *NOT* defined, so that we don't have
the system declaration and our declaration colliding.

Check for inet_aton, strncasecmp, and strptime with CMake, just as we do
with autotools.

Simplify the addition of {function_name_in_all_caps}_LO to libwsutil in
autotools.

Change-Id: Id5be5c73f79f81919a3a865324e400eca7b88889
Reviewed-on: https://code.wireshark.org/review/2903
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-07-06 21:03:09 +00:00
David Ameiss e1a8c9599f Standardize the names of, and document, the taps and heuristic dissector tables made avaialble by these dissectors.
Change-Id: If3a143eb9546c9de63cd32b2347000b09e0e3c93
Reviewed-on: https://code.wireshark.org/review/2688
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-29 00:03:35 +00:00
Guy Harris ce3d2ff3de Rename dissector_add_handle() to dissector_add_for_decode_as().
Hopefully that name makes it clear what the routiner's purpose is, and
will encourage people to use it rather than using dissector_add_uint()
with a bogus integer value.

Change-Id: Ic5be456d0ad40b176aab01712ab7b13aed5de2a8
Reviewed-on: https://code.wireshark.org/review/2483
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-06-20 16:43:56 +00:00
Michael Mann 73217d9f3f tvb_new_subset -> tvb_new_subset_length when length parameters are equal.
tvb_new_subset -> tvb_new_subset_remaining it appears that's what the intention is.

Change-Id: I2334bbf3f10475b3c22391392fc8b6864454de2d
Reviewed-on: https://code.wireshark.org/review/1999
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2014-06-07 15:41:07 +00:00
David Ameiss 037fb82c9a Minor changes to LBM dissectors:
(1) Display sequence numbers in both decimal and hex
(2) Fix an inconsistency in field naming between LBT-RU and LBT-RM.

bug:9718
Change-Id: I967062d6aa00ea9a3db51db94e56d37e68e642d3
Reviewed-on: https://code.wireshark.org/review/1531
Reviewed-by: Evan Huus <eapache@gmail.com>
2014-05-06 15:59:33 +00:00
David Ameiss 1a1abf9523 Conversation/memory scope fixes for LBM dissectors. See bug 9718.
Change-Id: I58aa249d73ab44f5f56b1559b38b216cdb542ecb
Reviewed-on: https://code.wireshark.org/review/1280
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-23 15:22:53 +00:00
Bill Meier 2d774c6f84 Minor cleanup
- Remove unneeded #includes;
- Move proto_reg_handoff...(() to the end of the file as per convention;
- Use dissector_add_handle() instead of using dissector_add_uint(..., 0, ...);
- #if 0 an unused global function (which caused a [-Wmissing-prototypes] warning);
- Remove an empty proto_reg-handoff...();
- 'if (already_registered)' not required in one case.

Change-Id: I74f267c2721df13eb4d52d7f19a6ded423218a39
Reviewed-on: https://code.wireshark.org/review/1277
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-04-22 15:00:57 +00:00
AndersBroman c68769765c Fix no previous prototype warnings.
Change-Id: I859597ebc957a58f659800ef63318f94e80feabf
Reviewed-on: https://code.wireshark.org/review/1104
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-04-14 12:50:31 +00:00
Guy Harris beb4876cb4 Don't assume the data pointed to by an address structure is aligned.
And don't assume you can dereference the pointer nonetheless; that
doesn't work on SPARC, for example - you get an unaligned-access trap.

Instead, use pntoh32() to fetch IPv4 address values from the address
structures.

While we're at it, just use guint32 for those addresses; we don't need
in_addr_t.

Change-Id: I84e6c653fe33b1bc6e67d9097ce423b82f1eb0c8
Reviewed-on: https://code.wireshark.org/review/1024
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 17:58:30 +00:00
Graham Bloice 7077aaa54f Fixes for Windows build post change 1006
Windows still needs the definition of in_addr_t

Change-Id: I43c417de8e8199cfa58b9d494be5e828f959f1a9
Reviewed-on: https://code.wireshark.org/review/1009
Reviewed-by: Graham Bloice <graham.bloice@trihedral.com>
Tested-by: Graham Bloice <graham.bloice@trihedral.com>
2014-04-08 11:31:37 +00:00
Guy Harris d3df2e588b On UN*X, <arpa/inet.h> suffices for struct in_addr and in_addr_t.
So don't pull in <netinet/in.h>.  Also, avoid <sys/types.h> in
packet-dcom.c.

While we're at it, do *not* assume that pinfo->src or pinfo->dst are
IPv4 addresses.

Change-Id: I5fc8e859780a8d863aaf6e90a21a7039cabae0e6
Reviewed-on: https://code.wireshark.org/review/1006
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2014-04-08 08:23:34 +00:00
Michael Mann 2f4ca9c8d9 Initial checkin of LBM aka 29West dissectors. See Bug 9718.
Change-Id: If8fcfe1971c8863f370e440f64c36eb7566f6852
Reviewed-on: https://code.wireshark.org/review/113
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-04-07 23:28:46 +00:00