Commit Graph

17 Commits

Author SHA1 Message Date
Gerald Combs 8d3ac3af86 epan: Convert our PROTO_ITEM_ macros to inline functions.
Convert our various PROTO_ITEM_ macros to inline functions and document
them.

Change-Id: I070b15d4f70d2189217a177ee8ba2740be36327c
Reviewed-on: https://code.wireshark.org/review/32706
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-04-04 04:03:38 +00:00
Gerald Combs 8c22c5bade Fix some spelling errors found by Lintian.
Change-Id: If6fc3aab7ad4fc634567121f7b9541bc6f6c5766
Reviewed-on: https://code.wireshark.org/review/30926
Reviewed-by: Gerald Combs <gerald@wireshark.org>
Petri-Dish: Gerald Combs <gerald@wireshark.org>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-12-05 18:58:19 +00:00
Guy Harris 89d2b33b38 Fix capitalization of preference display name.
They're supposed to use sentence case.

Change-Id: I28c5120fdfae14c628a2ffbfe6fc4b571f71767a
Reviewed-on: https://code.wireshark.org/review/30277
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2018-10-20 06:40:33 +00:00
Dario Lombardo fe219637a6 dissectors: use SPDX identifiers.
Change-Id: I92c94448e6641716d03158a5f332c8b53709423a
Reviewed-on: https://code.wireshark.org/review/25756
Petri-Dish: Dario Lombardo <lomato@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2018-02-12 16:49:58 +00:00
Pascal Quantin 8c89de612f TCAP: fix infinite loop introduced in g35f9349396
Bug: 13926
Change-Id: I6bb06639f1226d6f5faee614858f5f09953d3ff5
Reviewed-on: https://code.wireshark.org/review/23087
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2017-08-15 18:35:27 +00:00
Pascal Quantin 35f9349396 TCAP: more fixes for SRT analysis
- when building the END hash entry, always use the BEGIN destination
address. If no match is done, we will search using the BEGIN entry anyway
- add the source PC to the END hash entry. As it will be used for
messages initiated by the host that sent the BEGIN, we probably can
assume that the PC will not change

Bug: 13926
Change-Id: Iaa8b09bf6821961d1eab22683600f36d77bd2cc5
Reviewed-on: https://code.wireshark.org/review/23048
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-08-15 13:52:02 +00:00
Guy Harris 01f2e2b201 We really only need one range_foreach routine.
Rename range_foreach_r() to range_foreach(), getting rid of the old
range_foreach().

If your callback doesn't require an additional argument, just pass NULL
when calling range_foreach(), and declare the argument as unused.

Change-Id: I49a56f90610e39cf2ddc398c9e30ed11a6ca90db
Reviewed-on: https://code.wireshark.org/review/23025
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2017-08-08 22:06:27 +00:00
Pascal Quantin f434820705 TCAP: fix SRT analysis
When reviewing the code, the following issues were identified:
- otid/dtid on 3 bytes were not stored
- when receiving the first continue from dest, the TC_END hash entry was
created with the source tid / address instead of destination ones
- when receiving the first continue from src, the logic could prevent
the creation of the hash entry

Bug: 13739
Change-Id: If4ee70f0fa69f5ff74fdf75f3a741102baa0121a
Reviewed-on: https://code.wireshark.org/review/21780
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-06-02 12:13:48 +00:00
Pascal Quantin fb1a6320ec GSM MAP: use TCAP OTID to retrieve SM-RP-OA and SM-RP-DA fields when required
Bug: 13592
Change-Id: Ib8a0ff6d897699c44e5c4b8834123169066cf904
Reviewed-on: https://code.wireshark.org/review/21397
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2017-04-29 06:04:18 +00:00
Alexis La Goutte 9a8d90698b dissector: fix typo reponse -> response
Change-Id: I5d12b7038c0ed602cd5b3b416c35893986018f85
Reviewed-on: https://code.wireshark.org/review/20626
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-03-19 16:50:01 +00:00
Dario Lombardo 9bf42ae4dc tcap: convert GHashTables into wmem.
Change-Id: I95509cada53d363320a5a5d9e36612d7a85d7ef3
Reviewed-on: https://code.wireshark.org/review/19741
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-01-28 20:14:35 +00:00
Michael Mann 6a6d7ea34f Convert range API to always use wmem memory.
This is mostly to address memory leaks in range preferences (the biggest
user of range functionality) on shutdown.
Now range preferences must use epan scoped memory when referencing
internal preference structures to keep consistency.

Change-Id: Idc644f59b5b42fa1d46891542b53ff13ea754157
Reviewed-on: https://code.wireshark.org/review/19387
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Peter Wu <peter@lekensteyn.nl>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2017-01-07 00:44:10 +00:00
Michael Mann 6862820834 TCAP: Use a real dissector table to store dissector handles.
Also cleanup ANSI TCAP dissector that had a commented out attempt at what
was just cleaned up with TCAP.

Change-Id: I347f11e21a493d8d444c2dc528bb7713a227381a
Reviewed-on: https://code.wireshark.org/review/18129
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-11-06 13:55:00 +00:00
Michael Mann de90565452 packet-tcap.c: Remove MEM_TCAPSRT
No need to duplicate memory allocation of hash tables to have a "debug copy".
Maybe a separate wmem allocator can be used within the dissector, but that
type of debugging shouldn't be in trunk source. Keep it on private branch
until it's working.

Change-Id: I4bdd0f3d1b613f7ae79aa57ebb8e5c3293023253
Reviewed-on: https://code.wireshark.org/review/16282
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-07-04 20:44:35 +00:00
Michael Mann 04b82a7dc9 Convert AT_SS7PC to a "dissector address type"
The formatting of the address type is determined by a preference in
packet-mtp3.c, so just make MTP3 register the address type.
Use address_type_get_by_name in other dissectors (and export_pdu)
to use the address type.

Change-Id: Ifb32d7de27aeaa23cee8e803e25ffb3c905547b5
Reviewed-on: https://code.wireshark.org/review/15856
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2016-06-13 17:06:38 +00:00
Michael Mann 9bcac48403 Manually add protocol dependencies derived from find_dissector.
Started by grepping call_dissector_with_data, call_dissector_only and call_dissector and traced the handles passed into them to a find_dissector within the dissector.  Then replaced find_dissector with find_dissector_add_dependency and added the protocol id from the dissector.
"data" dissector was not considered to be a dependency.

Change-Id: I15d0d77301306587ef8e7af5876e74231816890d
Reviewed-on: https://code.wireshark.org/review/14509
Petri-Dish: Michael Mann <mmann78@netscape.net>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2016-03-20 12:48:48 +00:00
João Valverde 54a520d4a1 Move /asn1 to /epan/dissectors
Change-Id: I1208fe3c2ba428995526f561e8f792b8d871e9a9
Reviewed-on: https://code.wireshark.org/review/14388
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
Petri-Dish: Pascal Quantin <pascal.quantin@gmail.com>
Reviewed-by: João Valverde <j@v6e.pt>
2016-03-13 21:30:24 +00:00