Commit Graph

48005 Commits

Author SHA1 Message Date
Jakub Zawadzki 72ea2f9c9c Remove hfinfo->bitshift member, add hfinfo_bitshift() to get it.
svn path=/trunk/; revision=51174
2013-08-06 20:10:59 +00:00
Jakub Zawadzki 93f56d8a77 Optimize wrs_count_bitshift()
- Use __builtin_ctz for GCC/clang
- Do multiply and lookup on other platforms

svn path=/trunk/; revision=51173
2013-08-06 19:53:54 +00:00
Anders Broman fcc3728630 From Chris Bontje:
RTAC Serial Dissector Improvement for INFO Column Display.

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

svn path=/trunk/; revision=51172
2013-08-06 17:18:40 +00:00
Anders Broman 06c37f8665 Add code and a preference to use GSM SAPI to call sub dissectors.
https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9017

svn path=/trunk/; revision=51171
2013-08-06 17:11:42 +00:00
Anders Broman cc7c777f55 Store the port number as a string for the unresolved ports to avoid repeated calls to getservbyport() for all unresolved ports.
svn path=/trunk/; revision=51170
2013-08-06 17:07:20 +00:00
Jakub Zawadzki f6c55aa296 app_mem_usage fixes:
- Add missing feature test macro for pread()
- Fix $Id$ line

svn path=/trunk/; revision=51169
2013-08-06 16:38:36 +00:00
Martin Kaiser 1cfc59d2da remove unused variable numelem
this fixes
  CC     libdissectors_la-packet-scsi-smc.lo
packet-scsi-smc.c: In function 'dissect_smc_readelementstatus':
packet-scsi-smc.c:467:11: error: variable 'numelem' set but not used
[-Werror=unused-but-set-variable]


svn path=/trunk/; revision=51168
2013-08-06 07:33:49 +00:00
Jörg Mayer bde81de2c9 Improve loop a bit to reduce likelihood of dissector asserts
svn path=/trunk/; revision=51167
2013-08-06 04:55:48 +00:00
Michael Mann ac5ceb45fa Convert a few proto_tree_add_text to pacify checkAPIs.pl. Looks like the "proper" fix for the remaining calls would be to setup additional field types (to remove the tvb_get_ptr calls)
svn path=/trunk/; revision=51166
2013-08-06 01:11:55 +00:00
Michael Mann 1577a6992e Replace all proto_tree_add_text with filterable items.
svn path=/trunk/; revision=51165
2013-08-06 00:14:06 +00:00
Guy Harris 6a1626f907 Make sure serv_proto is set to the appropriate string value in all
cases; set it before we do the hash table lookup.  Don't initialize
serv_proto to null when we declare it - that covers up cases where we
fail to set it correctly.

Clean up indentation.

svn path=/trunk/; revision=51164
2013-08-05 20:23:45 +00:00
Jakub Zawadzki 518ac53e2c Make some global variables static
svn path=/trunk/; revision=51163
2013-08-05 20:15:06 +00:00
Martin Kaiser 5c813d0afe remove unnecessary if (tree) checks in packet-hdcp2.c,
which uses ptvcursor

svn path=/trunk/; revision=51162
2013-08-05 20:08:16 +00:00
Gerald Combs f22f8cc841 Fix the Python version check. Hopefully no one is running 1.5 or 1.6.
svn path=/trunk/; revision=51161
2013-08-05 20:08:11 +00:00
Martin Kaiser 0048fbc0d4 it's and, not or ;-)
this fixes
  CC     libwireshark_la-addr_resolv.lo
addr_resolv.c: In function 'serv_name_lookup':
addr_resolv.c:666:3: error: logical 'or' of collectively exhaustive tests is always true [-Werror=logical-op]

svn path=/trunk/; revision=51160
2013-08-05 19:40:22 +00:00
Jakub Zawadzki f4bcbeb9f2 Keep result of [new_]register_dissector in some dissectors. [2 of x]
(don't create new dissector handle if we can use already existing one)

svn path=/trunk/; revision=51159
2013-08-05 19:09:44 +00:00
Gerald Combs d3af98bb91 Don't force the use of Python 2.x, similar (but not identical to)
r51128. Print a warning if we're building with Python < 2.5.

svn path=/trunk/; revision=51158
2013-08-05 18:57:00 +00:00
Michael Mann 7207378cbd Replace global variable that was just used to pass data between dissectors with call_dissector_with_data.
svn path=/trunk/; revision=51157
2013-08-05 18:14:09 +00:00
Jakub Zawadzki 5fa2a99087 Keep result of [new_]register_dissector in some dissectors.
svn path=/trunk/; revision=51156
2013-08-05 18:09:43 +00:00
Anders Broman 9999016855 Try to make the OSX build bot happy.
svn path=/trunk/; revision=51155
2013-08-05 18:06:14 +00:00
Jakub Zawadzki b53052c6de Dissector handle after [new_]register_dissector can be get by find_dissector() so to avoid some extra calls just return it.
svn path=/trunk/; revision=51154
2013-08-05 17:23:47 +00:00
Anders Broman 21d5a76a68 Use a hastable for port resolution. Currently one table for the 4 protocols with resolution. SCTP and DCCP should perhaps be splited out to their own tables.
svn path=/trunk/; revision=51153
2013-08-05 16:36:24 +00:00
Michael Mann 86472b67df SCSI dissector does not parse PERSISTENT RESERVE commands correctly. Bug 9012 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9012).
From Bart Van Assche.

Changes:
- Add REGISTER AND MOVE and REPLACE LOST RESERVATION service actions.
- Decode the PARAMETER LIST LENGTH field correctly - this is a four
  byte field instead of a two byte field.
- For the REGISTER AND MOVE service action, add support for decoding
  the RELATIVE TARGET PORT IDENTIFIER, TRANSPORT ID LENGTH and
  TransportID fields.
- Fix parsing of the SERVICE ACTION field - this field is five bits
  wide instead of four.
- Move the definition of the "scsi.persresv.control.unreg" field just
  below the other REGISTER AND MOVE service action parameter list fields.

See also http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc4r36h.pdf.

- Only display persistent reservation information in a PERSISTENT
  RESERVE IN response if the ALLOCATION LENGTH field in the request
  was not zero.
- Correct the offset of the (SPC-2) SCOPE-SPECIFIC ADDRESS field.
  This field starts at offset 16 and not at offset 8.
- Correct the offsets of the SCOPE and TYPE fields. These fields
  are both contained in the byte at offset 21.
- Correct the base of the TRANSPORTID LENGTH field from BASE_HEX
  into BASE_NONE since this is the base required by non-numeric types.

For more information, see also:
* http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc4r36h.pdf
* http://www.t10.org/cgi-bin/ac.pl?t=f&f=spc2r20.pdf

svn path=/trunk/; revision=51152
2013-08-05 15:55:10 +00:00
Jeff Morriss bb6004a017 From Роман Донченко via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9010 :
This patch fixes a bug where if the client identifies itself first, both of
the protocol version messages are misidentified as encrypted data.

svn path=/trunk/; revision=51151
2013-08-05 14:53:19 +00:00
Jeff Morriss 4b0a541c7c Get rid of some unused and set-but-unused variables.
Un-shadow a variable.

Ensure a (new) tree variable is initialized.

Clean up trailing white space.

svn path=/trunk/; revision=51150
2013-08-05 13:17:37 +00:00
Michael Mann 635d8d4f2c Add support for determining BASE_EXT_STRING.
svn path=/trunk/; revision=51149
2013-08-05 12:16:50 +00:00
Michael Mann ad1d32485c Massive conversion to filterable items. It started with convert_proto_tree_add_text.pl, but continued as with many other cases that couldn't be handled by it (like using emem_strbuf_t to create groups of field strings).
Should now pacify bug 6844 (https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=6844)

svn path=/trunk/; revision=51148
2013-08-05 11:57:21 +00:00
Stig Bjørlykke 7861e5e426 Added gtk_adjustment_get_step_increment compat.
svn path=/trunk/; revision=51147
2013-08-05 11:53:05 +00:00
Jörg Mayer d9635daacc Fix some whitespace oddities
svn path=/trunk/; revision=51146
2013-08-05 11:31:41 +00:00
Stig Bjørlykke d4c0d96f1b From Øyvin Richardsen:
- Added up/down scrolling in Flow Graph window.
- Avoid segfault when mouse clicking below the last packet in the graph. 
- Fixed the Comment heading.

svn path=/trunk/; revision=51145
2013-08-05 11:16:12 +00:00
Michael Mann 81f3faf1e8 Completely remove support for proto_item_set_expert_flags.
svn path=/trunk/; revision=51144
2013-08-05 02:25:45 +00:00
Guy Harris 327f461190 Get rid of no-longer-used variables.
svn path=/trunk/; revision=51143
2013-08-05 02:14:39 +00:00
Michael Mann a22331bbd2 Convert remaining proto_item_set_expert_flags in dissector directory.
svn path=/trunk/; revision=51142
2013-08-05 01:54:15 +00:00
Jakub Zawadzki b67492bbc0 Cleanup tvb
- make tvb_ops->tvb_size a gsize field, not function call
- remove not needed forward declaration / forward line

svn path=/trunk/; revision=51141
2013-08-04 22:02:42 +00:00
Michael Mann af134c29ca Convert proto_item_set_expert_flags into filterable items.
svn path=/trunk/; revision=51140
2013-08-04 19:59:01 +00:00
Gerald Combs 1f9b980f00 [Automatic manuf, services and enterprise-numbers update for 2013-08-04]
svn path=/trunk/; revision=51137
2013-08-04 14:03:36 +00:00
Michael Mann 3eafc74e2b Convert proto_item_set_expert_flags to "filterable" items in alcap dissector. Unfortunately it had a few tentacles, so they needed to be brought along for the ride.
svn path=/trunk/; revision=51136
2013-08-04 13:46:25 +00:00
Michael Mann 30c5457f71 Convert proto_item_set_expert_flags into something filterable.
svn path=/trunk/; revision=51135
2013-08-04 13:08:59 +00:00
Martin Kaiser 0133cb60b5 dissect selector byte in the transport protocol descriptor
svn path=/trunk/; revision=51134
2013-08-04 11:35:54 +00:00
Michael Mann 14dd5e8e34 Ensure eth_hashtable exists when doing a lookup. Not sure I'm running into the same situation as Jeff (http://www.wireshark.org/lists/wireshark-dev/201308/msg00012.html), but tshark is complaining so I can't do fuzz-testing.
Also corrected copy/pasteo when cleaning up eth_hashtable.

svn path=/trunk/; revision=51133
2013-08-04 10:22:10 +00:00
Evan Huus d3470e7d2a Add a cast. Use g_snprintf instead of plain snprintf.
Should fix the buildbots.

svn path=/trunk/; revision=51132
2013-08-03 13:05:07 +00:00
Evan Huus de0d7c7f70 From Linas Vepstas via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=8961
Dissector for Stanag 4607 protocol.

From me:
- don't add expert info under if (tree)
- simplify loop and overflow checking

svn path=/trunk/; revision=51131
2013-08-03 12:35:31 +00:00
Jörg Mayer 6ab6208e3d Allow the python interpreter to be version 3 (2 being preferred)
svn path=/trunk/; revision=51128
2013-08-03 00:39:27 +00:00
Gerald Combs 09bfd96c5f Switch back to seasonal memory for the address UAT data since r50073
indicates that that's the correct thing to do for now.

svn path=/trunk/; revision=51127
2013-08-02 22:05:36 +00:00
Jeff Morriss 1c0960e4a9 From Роман Донченко via https://bugs.wireshark.org/bugzilla/show_bug.cgi?id=9006 :
Currently, Wireshark only dissects one side's Key Exchange Init message,
which, in particular, means that the encryption, MAC and compression
algorithms it infers are bogus.

This patch fixes that.

From me:

Don't use a macro which confused checkhf (it only saved a small amount of
visible code).  Fix up some more white space.

Use macros for a couple array indexes.

svn path=/trunk/; revision=51126
2013-08-02 21:56:28 +00:00
Gerald Combs 57e5534e5e Move the 802.15.4 address table hash entries to epan scope. Otherwise we
crash if we have an 802154_addresses UAT.

svn path=/trunk/; revision=51125
2013-08-02 21:45:56 +00:00
Gerald Combs bd33f6a366 Mention that building using Python 3 *should* work, but recommend using
2.7. Make the minimum version 2.5.

svn path=/trunk/; revision=51124
2013-08-02 16:37:45 +00:00
Gerald Combs 97c9a9b9ba Make sure we're compatible with Python 2 + 3. Tested with Pythons 2.5,
2.7, and 3.3. The contents of packet-ncp2222.c are different after the
changes (e.g. some array contents are in a different order) but the
output of running 'tshark -nVxr' on the NCP files in the menagerie are
identical.

svn path=/trunk/; revision=51123
2013-08-02 16:34:31 +00:00
Jeff Morriss d4baa69fd1 Add some casts.
svn path=/trunk/; revision=51122
2013-08-02 16:20:15 +00:00
Jeff Morriss b06ebbb17b Add some casts to keep C++ happy.
Mark an unused parameter as such.

#if out a currently unused function.

svn path=/trunk/; revision=51121
2013-08-02 15:27:19 +00:00