metze/wireshark/wip.git
10 years agoSort the list of encapsulation types, but still have Ethernet be the default.
Chris Maynard [Thu, 20 Jun 2013 16:40:46 +0000 (16:40 -0000)]
Sort the list of encapsulation types, but still have Ethernet be the default.

svn path=/trunk/; revision=50077

10 years agoFrom Michal Labedzki via
Evan Huus [Thu, 20 Jun 2013 16:31:53 +0000 (16:31 -0000)]
From Michal Labedzki via
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8824

Convert bluetooth emem trees to wmem trees.
Add modelines and fix indentation.
Correct typo in wmem_tree.h that still referred to emem.

svn path=/trunk/; revision=50076

10 years agoFrom Brian Otte via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8592
Evan Huus [Thu, 20 Jun 2013 16:22:53 +0000 (16:22 -0000)]
From Brian Otte via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8592

Numerous fixes and improvements to DHCPv6 Cable Television Labs vendor-specific
information dissection.

svn path=/trunk/; revision=50075

10 years agoLdap still needs to include wmem.h since it uses wmem during normal dissection,
Evan Huus [Thu, 20 Jun 2013 14:01:54 +0000 (14:01 -0000)]
Ldap still needs to include wmem.h since it uses wmem during normal dissection,
just not for UAT purposes.

svn path=/trunk/; revision=50074

10 years agoBack out some of the wmem conversions (r50063 and r50057).
Evan Huus [Thu, 20 Jun 2013 06:26:03 +0000 (06:26 -0000)]
Back out some of the wmem conversions (r50063 and r50057).

These dissectors allocate ephemeral or seasonal memory in UAT callbacks, which
really makes no sense because UAT callbacks can occur when there is no packet or
file in scope, making this effectively a leak if the user is fiddling with their
UAT and never opens a capture.

Emem let you get away with this, wmem forces an assertion. Back out the changes
so that the UATs are usable until the code can be properly fixed to not use
out-of-scope allocators.

svn path=/trunk/; revision=50073

10 years agoDon't assume $(uname) works; it's not a standard Bourne shell feature,
Guy Harris [Thu, 20 Jun 2013 00:27:52 +0000 (00:27 -0000)]
Don't assume $(uname) works; it's not a standard Bourne shell feature,
and we only assume a Bourne-compatible shell.

It's "OS X", not "OsX".

svn path=/trunk/; revision=50072

10 years agoAdd some missing wmem includes that apparently only show up on Windows.
Evan Huus [Wed, 19 Jun 2013 23:53:25 +0000 (23:53 -0000)]
Add some missing wmem includes that apparently only show up on Windows.

svn path=/trunk/; revision=50071

10 years agoFrom Dirk J via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8821
Evan Huus [Wed, 19 Jun 2013 23:52:54 +0000 (23:52 -0000)]
From Dirk J via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8821

if no make options are given to the macosx-setup.sh script by the user, the
script sets the number of parallel make jobs to 1.5x CPU cores.

Bonus enhancement: print the "export PKG_CONFIG_PATH" information in autogen.sh
on OsX, so people don't have to remember it.

svn path=/trunk/; revision=50070

10 years agoupdate the button in the status bar when a packet comment is added
Martin Kaiser [Wed, 19 Jun 2013 23:37:38 +0000 (23:37 -0000)]
update the button in the status bar when a packet comment is added
(this is a quick fix, the case when the last comment is removed
 is still not handled correctly)

svn path=/trunk/; revision=50069

10 years agoBased on patch from gyanesh via https://bugs.wireshark.org/bugzilla/show_bug.cgi...
Evan Huus [Wed, 19 Jun 2013 23:30:29 +0000 (23:30 -0000)]
Based on patch from gyanesh via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8268

Clarify display of the overload bit in multi-topology supported TLV for SPB.

svn path=/trunk/; revision=50068

10 years agoImplement bug 8675: show stream id in follow TCP stream window.
Martin Mathieson [Wed, 19 Jun 2013 23:27:12 +0000 (23:27 -0000)]
Implement bug 8675: show stream id in follow TCP stream window.

svn path=/trunk/; revision=50067

10 years agoApparently one of our major global headers must include emem.h, because I just
Evan Huus [Wed, 19 Jun 2013 23:08:58 +0000 (23:08 -0000)]
Apparently one of our major global headers must include emem.h, because I just
found a bunch more asn1 dissectors using emem without ever directly including
the header. Convert those to wmem as well, which involves add a number of
#include directives since dissectors do *not* automatically pull in the wmem
headers.

svn path=/trunk/; revision=50066

10 years agoFrom Orgad Shaneh via bug 8308 - allow a relative path for the WIRESHARK_LIBS location.
Graham Bloice [Wed, 19 Jun 2013 23:06:14 +0000 (23:06 -0000)]
From Orgad Shaneh via bug 8308 - allow a relative path for the WIRESHARK_LIBS location.

svn path=/trunk/; revision=50065

10 years agoFix for bug 6090. Clear the list store when resetting the dialog.
Martin Mathieson [Wed, 19 Jun 2013 22:57:39 +0000 (22:57 -0000)]
Fix for bug 6090.  Clear the list store when resetting the dialog.

svn path=/trunk/; revision=50064

10 years agoConvert the rest of the ASN1 dissectors from emem to wmem.
Evan Huus [Wed, 19 Jun 2013 22:47:36 +0000 (22:47 -0000)]
Convert the rest of the ASN1 dissectors from emem to wmem.

svn path=/trunk/; revision=50063

10 years agoFrom Anders:
Jeff Morriss [Wed, 19 Jun 2013 22:28:58 +0000 (22:28 -0000)]
From Anders:

Check Header CRC of SYNC protocol.

svn path=/trunk/; revision=50062

10 years agosupport extended size boxes, 2nd attempt
Martin Kaiser [Wed, 19 Jun 2013 22:26:12 +0000 (22:26 -0000)]
support extended size boxes, 2nd attempt
put up an expert info if the extended size does not fit into a gint

svn path=/trunk/; revision=50061

10 years agoAdd export of SS7 OPC/DPC
Pascal Quantin [Wed, 19 Jun 2013 21:49:12 +0000 (21:49 -0000)]
Add export of SS7 OPC/DPC

svn path=/trunk/; revision=50060

10 years agoFix display of "(correct)"/"(incorrect)" indication for the CRC.
Guy Harris [Wed, 19 Jun 2013 21:07:22 +0000 (21:07 -0000)]
Fix display of "(correct)"/"(incorrect)" indication for the CRC.

svn path=/trunk/; revision=50058

10 years agoConvert a batch of asn1 dissectors from emem to wmem.
Evan Huus [Wed, 19 Jun 2013 20:43:03 +0000 (20:43 -0000)]
Convert a batch of asn1 dissectors from emem to wmem.

svn path=/trunk/; revision=50057

10 years agoAnother iteration
Luis Ontanon [Wed, 19 Jun 2013 20:04:25 +0000 (20:04 -0000)]
Another iteration

svn path=/trunk/; revision=50056

10 years agoRework the change from r15595 a bit: when creating a TVB subset, always give
Jeff Morriss [Wed, 19 Jun 2013 19:31:40 +0000 (19:31 -0000)]
Rework the change from r15595 a bit: when creating a TVB subset, always give
the same captured and reported lengths so that we don't end up throwing
BoundsErrors ("Packet size limited during capture") when the packet is simply
malformed.

This fixes one of the issues reported in https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8816

svn path=/trunk/; revision=50055

10 years agoPreserve summary information when reordering a file
Pascal Quantin [Wed, 19 Jun 2013 19:31:06 +0000 (19:31 -0000)]
Preserve summary information when reordering a file

svn path=/trunk/; revision=50054

10 years agoIf the user turns off printing of the packet summary line, disable the column heading...
Chris Maynard [Wed, 19 Jun 2013 19:16:35 +0000 (19:16 -0000)]
If the user turns off printing of the packet summary line, disable the column headings checkbox; otherwise, enable it.

svn path=/trunk/; revision=50053

10 years agoTry to make it more obvious that you can select unselected task list
Gerald Combs [Wed, 19 Jun 2013 18:48:20 +0000 (18:48 -0000)]
Try to make it more obvious that you can select unselected task list
items.

svn path=/trunk/; revision=50052

10 years agoRemove col_headings_cb from print_cmd_toggle_detail() altogether. It's not needed...
Chris Maynard [Wed, 19 Jun 2013 18:44:42 +0000 (18:44 -0000)]
Remove col_headings_cb from print_cmd_toggle_detail() altogether.  It's not needed since if summary isn't printed, neither are column headings anyway.

svn path=/trunk/; revision=50051

10 years agoTry and keep r50047 and still fix
Evan Huus [Wed, 19 Jun 2013 18:38:52 +0000 (18:38 -0000)]
Try and keep r50047 and still fix
print_dlg.c:916: warning: value computed is not used

svn path=/trunk/; revision=50050

10 years agoOne of the unused hf's commented out in r47389 was not used due to a
Jeff Morriss [Wed, 19 Jun 2013 18:38:41 +0000 (18:38 -0000)]
One of the unused hf's commented out in r47389 was not used due to a
cut-n-pasteo.  Fix that cut-n-pasteo and reinstate the hf.

svn path=/trunk/; revision=50049

10 years agoRemove traling whitespace.
Jörg Mayer [Wed, 19 Jun 2013 18:33:49 +0000 (18:33 -0000)]
Remove traling whitespace.

svn path=/trunk/; revision=50048

10 years agoFix for
Jörg Mayer [Wed, 19 Jun 2013 18:30:04 +0000 (18:30 -0000)]
Fix for
Building C object ui/gtk/CMakeFiles/gtkui.dir/print_dlg.c.o
/home/jmayer/work/wireshark/svn/trunk/ui/gtk/print_dlg.c: In function ‘print_cmd_toggle_detail’:
/home/jmayer/work/wireshark/svn/trunk/ui/gtk/print_dlg.c:910:38: error: variable ‘col_headings_cb’ set but not used [-Werror=unused-but-set-variable]
   GtkWidget *print_bt, *summary_cb, *col_headings_cb, *details_cb;
                                      ^
cc1: all warnings being treated as errors

No idea wether the fix is correct. Compile tested only.

svn path=/trunk/; revision=50047

10 years agoRework wmem scoping limits so that users can still get a handle to a pool when
Evan Huus [Wed, 19 Jun 2013 18:28:13 +0000 (18:28 -0000)]
Rework wmem scoping limits so that users can still get a handle to a pool when
it is out of scope, they just can't *allocate* in the pool. This is necessary
because file-scope trees (migrating from emem) are set up on program
initialization when there is no file in scope - they need to initialize with the
handle, they just won't use it until a file is actually in scope.

svn path=/trunk/; revision=50046

10 years agoExplain how to enter a \ in an snmp field.
Jörg Mayer [Wed, 19 Jun 2013 18:20:59 +0000 (18:20 -0000)]
Explain how to enter a \ in an snmp field.

svn path=/trunk/; revision=50045

10 years agorevert the extended size box changes for now,
Martin Kaiser [Wed, 19 Jun 2013 18:10:41 +0000 (18:10 -0000)]
revert the extended size box changes for now,
this needs some more work to make things portable

svn path=/trunk/; revision=50044

10 years agoAdd a couple of missing lines from the usage output.
Martin Mathieson [Wed, 19 Jun 2013 18:06:46 +0000 (18:06 -0000)]
Add a couple of missing lines from the usage output.

svn path=/trunk/; revision=50043

10 years agoexplicitly use 64bit variables, g(u)int is not 64bit everywhere
Martin Kaiser [Wed, 19 Jun 2013 17:51:59 +0000 (17:51 -0000)]
explicitly use 64bit variables, g(u)int is not 64bit everywhere

svn path=/trunk/; revision=50042

10 years agoConvert DNS dissector to wmem, including first actual usage of wmem's red-black
Evan Huus [Wed, 19 Jun 2013 17:40:33 +0000 (17:40 -0000)]
Convert DNS dissector to wmem, including first actual usage of wmem's red-black
tree.

svn path=/trunk/; revision=50041

10 years agosupport extended size boxes, general cleanup
Martin Kaiser [Wed, 19 Jun 2013 17:34:43 +0000 (17:34 -0000)]
support extended size boxes, general cleanup

svn path=/trunk/; revision=50040

10 years agoAdd wmem_strbuf_new_label as just a sized new for label lengths.
Evan Huus [Wed, 19 Jun 2013 17:34:24 +0000 (17:34 -0000)]
Add wmem_strbuf_new_label as just a sized new for label lengths.

svn path=/trunk/; revision=50039

10 years agoAdd a comment about how it would nice for display filter macro fields
Martin Mathieson [Wed, 19 Jun 2013 17:11:55 +0000 (17:11 -0000)]
Add a comment about how it would nice for display filter macro fields
to use auto-completion, but that it won't work because the string
contains the $1, etc placeholders...

svn path=/trunk/; revision=50038

10 years agoTrivial: add a missing word, "to".
Chris Maynard [Wed, 19 Jun 2013 15:24:14 +0000 (15:24 -0000)]
Trivial: add a missing word, "to".

svn path=/trunk/; revision=50037

10 years agoAllow for column headers not to be printed in order to make it possible to export...
Chris Maynard [Wed, 19 Jun 2013 15:22:56 +0000 (15:22 -0000)]
Allow for column headers not to be printed in order to make it possible to export packets as plain text in a format that could then have a chance of being imported again (assuming other factors such as packet bytes were printed, etc.) in order to recover the original pcap file.
Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=1636

svn path=/trunk/; revision=50036

10 years agoetypes.h needs value_string.h
Martin Kaiser [Wed, 19 Jun 2013 14:56:11 +0000 (14:56 -0000)]
etypes.h needs value_string.h

svn path=/trunk/; revision=50035

10 years agoFet rid of a global variable
Pascal Quantin [Wed, 19 Jun 2013 07:16:14 +0000 (07:16 -0000)]
Fet rid of a global variable

svn path=/trunk/; revision=50034

10 years agoClean up wmem_strsplit to remove a bunch of weird switch statements and
Evan Huus [Wed, 19 Jun 2013 06:48:08 +0000 (06:48 -0000)]
Clean up wmem_strsplit to remove a bunch of weird switch statements and
unnecessary continue statements. Should fix the coverity issues Joerg pointed
out as well.

svn path=/trunk/; revision=50033

10 years agoGet rid of global variables
Pascal Quantin [Wed, 19 Jun 2013 06:44:39 +0000 (06:44 -0000)]
Get rid of global variables

svn path=/trunk/; revision=50032

10 years agoRegenerate dissector
Pascal Quantin [Wed, 19 Jun 2013 06:23:51 +0000 (06:23 -0000)]
Regenerate dissector

svn path=/trunk/; revision=50031

10 years agoFix CID 1033205: Dead default in switch (DEADCODE)
Jörg Mayer [Wed, 19 Jun 2013 03:30:06 +0000 (03:30 -0000)]
Fix CID 1033205: Dead default in switch (DEADCODE)

svn path=/trunk/; revision=50030

10 years agoFix CID 712341: Dereference null return value (NULL_RETURNS)
Jörg Mayer [Wed, 19 Jun 2013 03:23:31 +0000 (03:23 -0000)]
Fix CID 712341: Dereference null return value (NULL_RETURNS)

Well, not really. Just catch that case and error out.

svn path=/trunk/; revision=50029

10 years agoFix CID 1034293: Missing break in switch (MISSING_BREAK)
Jörg Mayer [Wed, 19 Jun 2013 02:54:45 +0000 (02:54 -0000)]
Fix CID 1034293: Missing break in switch (MISSING_BREAK)

svn path=/trunk/; revision=50028

10 years agoClarify (a V1.0 file might have a single zero byte at the end of the
Guy Harris [Wed, 19 Jun 2013 00:02:22 +0000 (00:02 -0000)]
Clarify (a V1.0 file might have a single zero byte at the end of the
page, which doesn't look like an "unused space" record because there
aren't two bytes of record type, just one byte).

svn path=/trunk/; revision=50027

10 years agoSlight stylistic cleanup - most routines, when defined, have no space
Guy Harris [Tue, 18 Jun 2013 23:47:50 +0000 (23:47 -0000)]
Slight stylistic cleanup - most routines, when defined, have no space
between the routine name and the opening parenthesis, so remove it from
the definition of the seek-read routine.

svn path=/trunk/; revision=50026

10 years agoNote that NetScaler trace files are page-oriented, with records not
Guy Harris [Tue, 18 Jun 2013 23:37:30 +0000 (23:37 -0000)]
Note that NetScaler trace files are page-oriented, with records not
split across page boundaries, rather than being a byte stream, and that
the last page may be short.

Fix some comments.

svn path=/trunk/; revision=50025

10 years agoAdd an option (switched off) to decode the Contention Resolution body as
Martin Mathieson [Tue, 18 Jun 2013 23:36:35 +0000 (23:36 -0000)]
Add an option (switched off) to decode the Contention Resolution body as
an RRC UL CCCH PDU.

svn path=/trunk/; revision=50024

10 years agoFrom Anders: Fix the highlighted length, add PDU description as a comment.
Jeff Morriss [Tue, 18 Jun 2013 23:33:00 +0000 (23:33 -0000)]
From Anders: Fix the highlighted length, add PDU description as a comment.

svn path=/trunk/; revision=50023

10 years agoAdd ability to export decrypted IPsec PDUs
Pascal Quantin [Tue, 18 Jun 2013 23:01:46 +0000 (23:01 -0000)]
Add ability to export decrypted IPsec PDUs

svn path=/trunk/; revision=50022

10 years agoSet PDCP SN length for DRBs for separate RRC element.
Martin Mathieson [Tue, 18 Jun 2013 22:38:54 +0000 (22:38 -0000)]
Set PDCP SN length for DRBs for separate RRC element.

svn path=/trunk/; revision=50021

10 years agoUpdate READMEs.
Evan Huus [Tue, 18 Jun 2013 21:47:18 +0000 (21:47 -0000)]
Update READMEs.

svn path=/trunk/; revision=50020

10 years agoAlso signal value of PDCP SN (only used if enabled by RLC preferences).
Martin Mathieson [Tue, 18 Jun 2013 21:44:48 +0000 (21:44 -0000)]
Also signal value of PDCP SN (only used if enabled by RLC preferences).

svn path=/trunk/; revision=50019

10 years agoResurrect wmem_memdup in its own misc. utilities group. Emem provides it, so we
Evan Huus [Tue, 18 Jun 2013 21:42:54 +0000 (21:42 -0000)]
Resurrect wmem_memdup in its own misc. utilities group. Emem provides it, so we
need to provide an analogue at least for now.

svn path=/trunk/; revision=50018

10 years agoAdd wmem_alloc_array, wmem_strsplit, wmem_strconcat.
Evan Huus [Tue, 18 Jun 2013 21:25:37 +0000 (21:25 -0000)]
Add wmem_alloc_array, wmem_strsplit, wmem_strconcat.

svn path=/trunk/; revision=50017

10 years agoConfigure MAC LCID -> RLC channel settings from RRC.
Martin Mathieson [Tue, 18 Jun 2013 21:02:00 +0000 (21:02 -0000)]
Configure MAC LCID -> RLC channel settings from RRC.

svn path=/trunk/; revision=50016

10 years agoPass hfinfo and not hfindex to internal proto functions.
Jakub Zawadzki [Tue, 18 Jun 2013 20:52:31 +0000 (20:52 -0000)]
Pass hfinfo and not hfindex to internal proto functions.

svn path=/trunk/; revision=50015

10 years agoUpdate "TTL low or unexpected" coloring rule to ignore vrrp, carp and MulticastDNS...
Michael Mann [Tue, 18 Jun 2013 20:48:42 +0000 (20:48 -0000)]
Update "TTL low or unexpected" coloring rule to ignore vrrp, carp and MulticastDNS all of which intentionally use TTL 255.  Bug 5010 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=5010)

Add carp to routing protocols while we're at it.

svn path=/trunk/; revision=50014

10 years agoRefactor insert32 to use lookup_or_insert32 with the right flags.
Evan Huus [Tue, 18 Jun 2013 19:55:29 +0000 (19:55 -0000)]
Refactor insert32 to use lookup_or_insert32 with the right flags.

svn path=/trunk/; revision=50013

10 years agoRefactor lookup_or_insert32 to remove a bunch of continue and break statements
Evan Huus [Tue, 18 Jun 2013 19:43:18 +0000 (19:43 -0000)]
Refactor lookup_or_insert32 to remove a bunch of continue and break statements
as well as a confusing while(TRUE).

svn path=/trunk/; revision=50012

10 years agoSimplify node structure. Use a boolean for whether or not it's a subtree, and an
Evan Huus [Tue, 18 Jun 2013 19:32:40 +0000 (19:32 -0000)]
Simplify node structure. Use a boolean for whether or not it's a subtree, and an
enum for the color (red/black). Don't use bitfields since they don't save us
much (if anything) in terms of space and don't nest the fields in their own
anonymous struct.

svn path=/trunk/; revision=50011

10 years agoFactor function for node creation out and use it in several places.
Evan Huus [Tue, 18 Jun 2013 19:19:21 +0000 (19:19 -0000)]
Factor function for node creation out and use it in several places.

svn path=/trunk/; revision=50010

10 years agoScrap wmem_memdup, it's not actually as useful as I thought it would be.
Evan Huus [Tue, 18 Jun 2013 19:01:01 +0000 (19:01 -0000)]
Scrap wmem_memdup, it's not actually as useful as I thought it would be.

svn path=/trunk/; revision=50009

10 years agoFactor common code for red-black tree array lookups into a helper function and
Evan Huus [Tue, 18 Jun 2013 18:57:28 +0000 (18:57 -0000)]
Factor common code for red-black tree array lookups into a helper function and
use it for both direct lookups and less-than-or-equal-to lookups.

svn path=/trunk/; revision=50008

10 years agoRemove wmem_tree_create_subtree, it does nothing we can't do with
Evan Huus [Tue, 18 Jun 2013 17:48:04 +0000 (17:48 -0000)]
Remove wmem_tree_create_subtree, it does nothing we can't do with
wmem_tree_new.

svn path=/trunk/; revision=50007

10 years agoFactor string-packing code into a common function to use in both insert_string
Evan Huus [Tue, 18 Jun 2013 17:39:15 +0000 (17:39 -0000)]
Factor string-packing code into a common function to use in both insert_string
and lookup_string.

svn path=/trunk/; revision=50006

10 years agoFix compile error:
Jörg Mayer [Tue, 18 Jun 2013 12:22:40 +0000 (12:22 -0000)]
Fix compile error:

[ 79%] Building C object CMakeFiles/text2pcap.dir/text2pcap.c.o
In file included from /usr/include/glib-2.0/glib/galloca.h:34:0,
                 from /usr/include/glib-2.0/glib.h:32,
                 from /home/jmayer/work/wireshark/svn/trunk/wsutil/file_util.h:34,
                 from /home/jmayer/work/wireshark/svn/trunk/text2pcap.c:116:
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c: In function ‘write_current_packet’:
/usr/include/glib-2.0/glib/gtypes.h:186:22: error: declaration of ‘__v’ shadows a previous local [-Werror=shadow]
  ({ register guint16 __v, __x = ((guint16) (val)); \
                      ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:359:23: note: in expansion of macro ‘GUINT16_TO_BE’
 #define g_htons(val) (GUINT16_TO_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:35: note: in expansion of macro ‘g_htons’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                   ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:327:31: note: in expansion of macro ‘GUINT16_TO_BE’
 #define GUINT16_FROM_BE(val) (GUINT16_TO_BE (val))
                               ^
/usr/include/glib-2.0/glib/gtypes.h:357:23: note: in expansion of macro ‘GUINT16_FROM_BE’
 #define g_ntohs(val) (GUINT16_FROM_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:52: note: in expansion of macro ‘g_ntohs’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                                    ^
/usr/include/glib-2.0/glib/gtypes.h:186:22: error: shadowed declaration is here [-Werror=shadow]
  ({ register guint16 __v, __x = ((guint16) (val)); \
                      ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:359:23: note: in expansion of macro ‘GUINT16_TO_BE’
 #define g_htons(val) (GUINT16_TO_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:35: note: in expansion of macro ‘g_htons’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                   ^
/usr/include/glib-2.0/glib/gtypes.h:186:27: error: declaration of ‘__x’ shadows a previous local [-Werror=shadow]
  ({ register guint16 __v, __x = ((guint16) (val)); \
                           ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:359:23: note: in expansion of macro ‘GUINT16_TO_BE’
 #define g_htons(val) (GUINT16_TO_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:35: note: in expansion of macro ‘g_htons’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                   ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:327:31: note: in expansion of macro ‘GUINT16_TO_BE’
 #define GUINT16_FROM_BE(val) (GUINT16_TO_BE (val))
                               ^
/usr/include/glib-2.0/glib/gtypes.h:357:23: note: in expansion of macro ‘GUINT16_FROM_BE’
 #define g_ntohs(val) (GUINT16_FROM_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:52: note: in expansion of macro ‘g_ntohs’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                                    ^
/usr/include/glib-2.0/glib/gtypes.h:186:27: error: shadowed declaration is here [-Werror=shadow]
  ({ register guint16 __v, __x = ((guint16) (val)); \
                           ^
/usr/include/glib-2.0/glib/gtypes.h:237:38: note: in expansion of macro ‘GUINT16_SWAP_LE_BE_IA32’
 #    define GUINT16_SWAP_LE_BE(val) (GUINT16_SWAP_LE_BE_IA32 (val))
                                      ^
/usr/lib/glib-2.0/include/glibconfig.h:192:29: note: in expansion of macro ‘GUINT16_SWAP_LE_BE’
 #define GUINT16_TO_BE(val) (GUINT16_SWAP_LE_BE (val))
                             ^
/usr/include/glib-2.0/glib/gtypes.h:359:23: note: in expansion of macro ‘GUINT16_TO_BE’
 #define g_htons(val) (GUINT16_TO_BE (val))
                       ^
/home/jmayer/work/wireshark/svn/trunk/text2pcap.c:705:35: note: in expansion of macro ‘g_htons’
             pseudoh.length      = g_htons(length - g_ntohs(HDR_IPv6.ip6_ctlun.ip6_un1.ip6_un1_plen) + sizeof(HDR_UDP));
                                   ^
cc1: all warnings being treated as errors
make[2]: *** [CMakeFiles/text2pcap.dir/text2pcap.c.o] Error 1

Feel free to choose a less offensive variable name

svn path=/trunk/; revision=50005

10 years agoAdd test block for wmem_tree_lookup32_array_le(), fix other tests where certain
Evan Huus [Tue, 18 Jun 2013 06:22:47 +0000 (06:22 -0000)]
Add test block for wmem_tree_lookup32_array_le(), fix other tests where certain
random seeds would cause collisions and false failures.

svn path=/trunk/; revision=50004

10 years agoWmem tree tests with non-trivial keys.
Evan Huus [Tue, 18 Jun 2013 05:41:16 +0000 (05:41 -0000)]
Wmem tree tests with non-trivial keys.

svn path=/trunk/; revision=50003

10 years agoRe-port a bunch of the red-black tree code from wmem with fewer modifications,
Evan Huus [Tue, 18 Jun 2013 05:31:12 +0000 (05:31 -0000)]
Re-port a bunch of the red-black tree code from wmem with fewer modifications,
and enable the tests.

Lesson: make it work, *then* refactor it into sanity.

svn path=/trunk/; revision=50002

10 years agoAdd ability to export decrypted SSL/DTLS PDUs
Pascal Quantin [Tue, 18 Jun 2013 01:13:07 +0000 (01:13 -0000)]
Add ability to export decrypted SSL/DTLS PDUs

svn path=/trunk/; revision=50001

10 years agoFrom Anders:
Jeff Morriss [Tue, 18 Jun 2013 01:08:17 +0000 (01:08 -0000)]
From Anders:

Use integers intead of strings for hf_sync_timestamp
And hf_sync_packet_nr.
Ad ref. to specification.

svn path=/trunk/; revision=50000

10 years agoDon't limit the on-the-wire length of packets to 64KB, there are larger packets
Evan Huus [Tue, 18 Jun 2013 01:02:26 +0000 (01:02 -0000)]
Don't limit the on-the-wire length of packets to 64KB, there are larger packets
out there (especially over USB) and we should be able to load them as long as
they are snapped to a sane length.

Also validate that packets do not specify a snapshot length larger than the one
in the file header, though only make it a warning, as this is not necessarily a
fatally corrupt packet.

https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8808

svn path=/trunk/; revision=49999

10 years agoAdd tests for red-black tree array keys, if0-ed out until I can make them not
Evan Huus [Tue, 18 Jun 2013 00:21:32 +0000 (00:21 -0000)]
Add tests for red-black tree array keys, if0-ed out until I can make them not
blow up. Not sure if the tests are wrong or if I broke something during the port
from wmem...

svn path=/trunk/; revision=49998

10 years agoYet another iteration
Luis Ontanon [Mon, 17 Jun 2013 23:45:42 +0000 (23:45 -0000)]
Yet another iteration

svn path=/trunk/; revision=49997

10 years agoPut the code to fill in the struct wtap_pkthdr and to read the packet
Guy Harris [Mon, 17 Jun 2013 23:43:55 +0000 (23:43 -0000)]
Put the code to fill in the struct wtap_pkthdr and to read the packet
data into a common routine, and use it in both the read and seek-read
routines.

svn path=/trunk/; revision=49996

10 years agoFrom Dirk Jagdmann via bug 7525: macosx-setup.sh improvements.
Gerald Combs [Mon, 17 Jun 2013 23:30:56 +0000 (23:30 -0000)]
From Dirk Jagdmann via bug 7525: macosx-setup.sh improvements.

svn path=/trunk/; revision=49995

10 years agoFix qt make buildbot step
Alexis La Goutte [Mon, 17 Jun 2013 22:56:35 +0000 (22:56 -0000)]
Fix qt make buildbot step

Qt make don't like cp ../../lib/lib{wireshark,wiretap,wsutil}.* .
cp: cannot stat `../../lib/lib{wireshark,wiretap,wsutil}.*': No such file or directory

svn path=/trunk/; revision=49994

10 years agoExtract some common code for array lookups, and replace some DISSECTOR
Evan Huus [Mon, 17 Jun 2013 22:51:50 +0000 (22:51 -0000)]
Extract some common code for array lookups, and replace some DISSECTOR
assertions with regular glib assertions - there's no guarantee that wmem code
will always be run from within a dissector.

svn path=/trunk/; revision=49993

10 years agoFrom Niels de Vos via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8810
Evan Huus [Mon, 17 Jun 2013 22:41:43 +0000 (22:41 -0000)]
From Niels de Vos via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8810

Use value_string array names_nfs4_operation_ext for nfs.main_opname, just like
nfs.opname does.

svn path=/trunk/; revision=49992

10 years agoFix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8809
Evan Huus [Mon, 17 Jun 2013 22:22:17 +0000 (22:22 -0000)]
Fix https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8809

The LLRP Standard 1.0.1 defines the ProtocolID Parameter as 8 bit value (see
LLRP Standard 1.0.1 document, page 138, AccessSpecParameter) but Wireshark
treats it as 16 bit value and therefore doesn't recognize the
EPCGlobalClass1Gen2 protocol type and marks the whole packet afterwards as
invalid.

svn path=/trunk/; revision=49991

10 years agoMerge more of the read and seek-read code paths.
Guy Harris [Mon, 17 Jun 2013 22:18:24 +0000 (22:18 -0000)]
Merge more of the read and seek-read code paths.

svn path=/trunk/; revision=49990

10 years agoMore PDU export work:
Pascal Quantin [Mon, 17 Jun 2013 21:54:21 +0000 (21:54 -0000)]
More PDU export work:
- add automatic export of port type when exporting a source / destination port
- add export of SCTP PPID (usefulness to be checked)
- fix some field size

svn path=/trunk/; revision=49989

10 years agoMerge "read record header" and "read packet data" routines into a single
Guy Harris [Mon, 17 Jun 2013 21:18:47 +0000 (21:18 -0000)]
Merge "read record header" and "read packet data" routines into a single
routine, used both by read and seek-read routines.

svn path=/trunk/; revision=49988

10 years agoFix 7bit ASCII / IA5 SMS dissection broken in r49910
Pascal Quantin [Mon, 17 Jun 2013 19:52:01 +0000 (19:52 -0000)]
Fix 7bit ASCII / IA5 SMS dissection broken in r49910

svn path=/trunk/; revision=49986

10 years agoEnsure that the length parameter to dissect_per_length_determinant is
Evan Huus [Mon, 17 Jun 2013 19:25:45 +0000 (19:25 -0000)]
Ensure that the length parameter to dissect_per_length_determinant is
initialized even in cases where we error or otherwise fail to dissect.

Fixes https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8722

Thanks to Pascal for his help digging through this one.

svn path=/trunk/; revision=49985

10 years agoApply r49983 to other dissectors
Pascal Quantin [Mon, 17 Jun 2013 18:44:19 +0000 (18:44 -0000)]
Apply r49983 to other dissectors

svn path=/trunk/; revision=49984

10 years agotvb_length_remaining() can return -1 so don't cast its return value to an unsigned...
Chris Maynard [Mon, 17 Jun 2013 15:39:56 +0000 (15:39 -0000)]
tvb_length_remaining() can return -1 so don't cast its return value to an unsigned type when performing integer comparisons.  Instead, cast strlen()'s return value to a signed type and perform the comparison that way.
#BACKPORT(1.10,1.8)

svn path=/trunk/; revision=49983

10 years agoMisc tweaks to packet-http-urlencoded.c
Evan Huus [Mon, 17 Jun 2013 14:18:23 +0000 (14:18 -0000)]
Misc tweaks to packet-http-urlencoded.c
- add modelines
- convert emem to wmem
- add cast to satisfy my version of GCC

svn path=/trunk/; revision=49982

10 years agothe Licence
Luis Ontanon [Mon, 17 Jun 2013 09:17:48 +0000 (09:17 -0000)]
the Licence

svn path=/trunk/; revision=49981

10 years agoChecking in as it compiles...
Luis Ontanon [Mon, 17 Jun 2013 09:11:30 +0000 (09:11 -0000)]
Checking in as it compiles...

svn path=/trunk/; revision=49980

10 years agoFix typo.
Michael Tüxen [Mon, 17 Jun 2013 08:08:14 +0000 (08:08 -0000)]
Fix typo.

svn path=/trunk/; revision=49979

10 years agoFix for previous commit, don't use string if get_form_key_value() failed.
Jakub Zawadzki [Mon, 17 Jun 2013 07:41:48 +0000 (07:41 -0000)]
Fix for previous commit, don't use string if get_form_key_value() failed.

svn path=/trunk/; revision=49978

10 years agoAdd small dissector for application/x-www-form-urlencoded
Jakub Zawadzki [Mon, 17 Jun 2013 07:35:30 +0000 (07:35 -0000)]
Add small dissector for application/x-www-form-urlencoded

svn path=/trunk/; revision=49977

10 years agoAdded a missing CFRelease.
Stig Bjørlykke [Mon, 17 Jun 2013 07:20:54 +0000 (07:20 -0000)]
Added a missing CFRelease.

svn path=/trunk/; revision=49976