Commit Graph

31 Commits

Author SHA1 Message Date
Ronnie Sahlberg feab79e328 change a whole bunch of ethereal into wireshark
svn path=/trunk/; revision=18196
2006-05-21 04:49:01 +00:00
Olivier Biot f0c3253d6e Fix coverity Error CID: 15.
svn path=/trunk/; revision=17553
2006-03-09 16:21:39 +00:00
Olivier Biot 5cd8dbd028 Fix Coverity issue CID: 14 in wkh_accept_encoding().
svn path=/trunk/; revision=17539
2006-03-08 22:52:31 +00:00
Olivier Biot e931881626 Use g_print() instead of fprintf() to write messages to the debug console.
svn path=/trunk/; revision=16373
2005-11-01 18:18:46 +00:00
Gerald Combs c975c8e67a Use tvb_free() instead of g_free() to free tvbuffs.
svn path=/trunk/; revision=16220
2005-10-14 15:55:58 +00:00
Olivier Biot 6f5e84b2d7 Fix bug 492 - the MMSE dissector calls add_content_type() defined in WSP, which
uses proto_item_append_string(). The visibility hack must be present, otherwise
a dissector assert is generated within the MMSE dissector.

svn path=/trunk/; revision=16060
2005-09-30 19:29:21 +00:00
Olivier Biot 122105370d Part 2 of the fix: also add the correct offset for non-WSP address records.
svn path=/trunk/; revision=16014
2005-09-26 20:49:33 +00:00
Olivier Biot 875fb98655 Fix WSP redirect and SIR address parsing:
- The incorrect number of octets were highlighted (bearer type and port number
   were disregarded).

 - In SIR version 1 content, correct the parsing (full WSP address length was
   not added to the offset for parsing the non-WSP contact points).

svn path=/trunk/; revision=16012
2005-09-26 20:00:37 +00:00
Guy Harris 25c4bc9379 Replace tvb_memcpy() calls that extract IPv4 addresses into a guint32,
and that extract IPv6 addresses into a "struct e_in6_addr", with
tvb_get_ipv4() and tvb_get_ipv6() calls - except for some that we
remove, by using proto_tree_add_item(), rather than replacing.

Have epan/tvbuff.h include epan/ipv6-utils.h, to define "struct
e_in6_addr" (not necessary to declare the tvbuff routines, but including
it there means "struct e_in6_addr" is guaranteed to be defined before
those declarations, so we don't get compiler complaints if we define it
*after* those declarations).

svn path=/trunk/; revision=15758
2005-09-11 21:25:37 +00:00
Ronnie Sahlberg e3a0e74e8d some more tcv_get_stringz() to tvb_get_ephemeral_stringz() conversions
svn path=/trunk/; revision=15288
2005-08-11 07:44:38 +00:00
Ronnie Sahlberg ec3ab9ec3e rename ep_tvb_get_string() to tvb_get_ephemeral_string() asnd update the documentation in README.developer
svn path=/trunk/; revision=15270
2005-08-10 13:41:13 +00:00
Ulf Lamping 0dc9fb3d4a various code cleanup:
-use g_snprintf instead of sprintf and snprintf
-use g_strdup_printf where appropriate
-remove #include "snprintf.h" (as only g_snprintf should be used)
-replace some more alloc/realloc/calloc/free with their glib pendants

svn path=/trunk/; revision=15264
2005-08-08 18:50:39 +00:00
Ronnie Sahlberg a2142fd8f1 more emeification of tvb_get_string()
svn path=/trunk/; revision=15133
2005-07-28 10:05:37 +00:00
Luis Ontanon 10f8560838 avoid a crash when tree is null
svn path=/trunk/; revision=15008
2005-07-23 02:07:02 +00:00
Guy Harris ab797734dd Get rid of the private "my_match_strval()" routine in many dissectors;
add a "match_strval_idx()" routine that does the same thing, and have
"match_strval()" call it.

Make those routines, and "val_to_str()", return a "const" pointer. 
Update dissectors as necessary to squelch compiler warnings produced by
that.

Use "val_to_str()" rather than using "match_strval()" and then, if the
result is null, substituting a specific string.  Clean up some other
"match_strval()"/"val_to_str()" usages.

Add a null pointer check in the NDPS dissector's "attribute_value()"
routine, as it's not clear that "global_attribute_name" won't be null at
that point.

Make some global variables in the AFS4INT dissector local.

Make some routines not used outside the module they're in static.

Make some tables "static const".

Clean up white space.

Fix Gerald's address in some files.

svn path=/trunk/; revision=14786
2005-06-26 19:56:52 +00:00
Ronnie Sahlberg 6879e6da67 from didier fix for the regression for bug 62
svn path=/trunk/; revision=14457
2005-05-27 21:33:27 +00:00
Ronnie Sahlberg 864245ef6e cket wsp is creating string items and later appending to them and their value at runtime which breaks when the TRY_TO_FAKE_THIS_ITEM() is used.
Add a comment to proto_item_append_string() explaining the "danger" and what needs to be done if one decides to use proto_item_append_string()

Add a small change to WSP so that it will disable this speed optimization so not to trigger a DISSECTOR_BUG in proto_item_append_string()




svn path=/trunk/; revision=14452
2005-05-27 06:00:08 +00:00
Gerald Combs efd08d91bc Add even more calls to tvb_ensure_bytes_exist().
svn path=/trunk/; revision=14111
2005-04-17 05:11:25 +00:00
Gerald Combs 67a2c952a6 Ham-fistedly drop in a bunch of tvb_ensure_bytes_exist() calls. One of
them fixes bug 46.

svn path=/trunk/; revision=14110
2005-04-17 01:42:10 +00:00
Gerald Combs d19929cd62 Add a few tvb_ensure_bytes_exist() calls. Fixes bug 35.
svn path=/trunk/; revision=14109
2005-04-16 22:25:54 +00:00
Gerald Combs 05ae084f5b Fix brokenness from previous patch.
svn path=/trunk/; revision=14031
2005-04-08 20:28:24 +00:00
Gerald Combs 388c7e2da9 Add a length check, fix up some comments.
svn path=/trunk/; revision=14029
2005-04-08 19:09:46 +00:00
Gerald Combs c92c1df4a4 Try not to call proto_tree_add_text() with negative lengths in error messages.
svn path=/trunk/; revision=14018
2005-04-05 14:40:59 +00:00
Guy Harris 189c2652f7 "tvb_get_stringz()" and "abs_time_to_str()" don't return null pointers,
so don't check whether they've done so with "DISSECTOR_ASSERT()". 
("proto_item_set_string()" and friends already do so.)

Fix indentation.

svn path=/trunk/; revision=13876
2005-03-23 03:51:38 +00:00
Olivier Biot 71d79f31c0 As suggested by Ulf Lamping, prevent Ethereal from bailing out if there's a protocol error, as we now have a DISSECTOR_ASSERT() macro.
svn path=/trunk/; revision=13869
2005-03-22 22:27:14 +00:00
Ulf Lamping b955abc3ed bugfix for buildbot randpkt: don't call proto_tree_add_string with a NULL pointer
TO THE DISSECTOR DEVELOPERS, PLEASE FIX THIS: I could easily found several places where a g_assert is called, depending on the input packet data. NEVER DO THIS, as this crashes Ethereal simply by invalid packet data input!!!

svn path=/trunk/; revision=13868
2005-03-22 21:47:11 +00:00
Anders Broman 851ecd2ac4 From Jon Ringle:
1) Added a setup_frame parameter to conversation_t
2) Used the conversation_t next to maintain a list of conversations with the 
same src/dest tuple but different setup_frame number.
3) Changed the signature of find_conversation() and conversation_new() to pass 
in the frame number.
4) Adjusted packet-sdp to select RTP conversation if both m=audio and m=image 
are present, and T.38 conversation if only m=image is present. I expect that 
RTP/T.38 dissecting to be better, but I don't have a way to generate T.38 
packets.

svn path=/trunk/; revision=13243
2005-02-02 20:07:03 +00:00
Guy Harris e20d80ea57 Use "plurality()" rather than locally-defined "PLURALIZE()" macros, and
get rid of the definition of "PLURALIZE()" in modules that don't use it.

svn path=/trunk/; revision=12791
2004-12-20 22:13:48 +00:00
Gerald Combs d45961b73f Replace a few instances of match_strval() with val_to_str().
svn path=/trunk/; revision=12625
2004-11-30 16:52:21 +00:00
Guy Harris 6472876ab3 Move the tap infrastructure to the epan directory.
svn path=/trunk/; revision=12128
2004-09-29 00:06:36 +00:00
Gilbert Ramirez 669db206cb Move dissectors to epan/dissectors directory.
Also move ncp222.py, x11-fields, process-x11-fields.pl,
make-reg-dotc, and make-reg-dotc.py.

Adjust #include lines in files that include packet-*.h
files.

svn path=/trunk/; revision=11410
2004-07-18 18:06:47 +00:00