Commit Graph

32 Commits

Author SHA1 Message Date
Martin Mathieson d17c018013 tools/check_typed_item_calls: check FT_BOOLEAN mask length 2022-12-15 13:28:05 +00:00
Guy Harris 5d053016c4 Remove a byte-order mark from two files.
Fixes #17440.
2021-06-10 21:33:08 -07:00
Martin Mathieson 11e919898c Set a few more dissector vars/funs to static.
These are the last of the easy ones to fix/set.
2021-02-15 09:20:58 +00:00
Martin Mathieson c1ff6b3675 Fix some more item lengths. 2020-11-19 21:18:21 +00:00
Guy Harris e1d9a226a2 Fix the type of arrays of pointers to hf_ values for bitfield routines.
The static arrays are supposed to be arrays of const pointers to int,
not arrays of non-const pointers to const int.

Fixing that means some bugs (scribbling on what's *supposed* to be a
const array) will be caught (see packet-ieee80211-radiotap.c for
examples, the first of which inspired this change and the second of
which was discovered while testing compiles with this change), and
removes the need for some annoying casts.

Also make some of those arrays static while we're at it.

Update documentation and dissector-generator tools.

Change-Id: I789da5fc60aadc15797cefecfd9a9fbe9a130ccc
Reviewed-on: https://code.wireshark.org/review/37517
Petri-Dish: Guy Harris <gharris@sonic.net>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2020-06-19 11:32:26 +00:00
Guy Harris 20800366dd HTTPS (almost) everywhere.
Change all wireshark.org URLs to use https.

Fix some broken links while we're at it.

Change-Id: I161bf8eeca43b8027605acea666032da86f5ea1c
Reviewed-on: https://code.wireshark.org/review/34089
Reviewed-by: Guy Harris <guy@alum.mit.edu>
2019-07-26 18:44:40 +00:00
Anders Broman 3b97267bad A21/s102: Fiix/pretify display of Correlation Id.
Change-Id: I239db6304f3bdc70ddf8747d3e750494845092fe
Reviewed-on: https://code.wireshark.org/review/33291
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Tested-by: Petri Dish Buildbot
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-05-21 10:13:20 +00:00
Anders Broman 75da45dc4e A21/s102: Improve Mobile Subscription information dissection.
Change-Id: I55a644f256616d2c3244977e897cc351a0d16876
Reviewed-on: https://code.wireshark.org/review/33277
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-05-20 14:48:11 +00:00
Dario Lombardo f32638d67d a21: mark parameter unused.
Change-Id: I1124ac61f49c5c5e7767246163d144919fa8e0d5
Reviewed-on: https://code.wireshark.org/review/33276
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-05-20 14:47:52 +00:00
Anders Broman e05fac3ec0 A21/s102: Dissect Pilot List.
Change-Id: I6549232daa67ab1047da0b07b68d39ed6cc648f5
Reviewed-on: https://code.wireshark.org/review/33273
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2019-05-20 13:19:38 +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
Michael Mann 2eb7b05b8c Convert most UDP dissectors to use "auto" preferences.
Similar to the "tcp.port" changes in I99604f95d426ad345f4b494598d94178b886eb67,
convert dissectors that use "udp.port".

More cleanup done on dissectors that use both TCP and UDP dissector
tables, so that less preference callbacks exist.

Change-Id: If07be9b9e850c244336a7069599cd554ce312dd3
Reviewed-on: https://code.wireshark.org/review/18120
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-10-13 02:51:18 +00:00
Joerg Mayer 8f3ad91905 Fix some warnings/errors of type
git/epan/dissectors/packet-a21.c:478:25: error: 'item' was marked unused but was used
      [-Werror,-Wused-but-marked-unused]
        proto_item_append_text(item, "%s", val_to_str_const(event_id, a21_event_vals, "Unknown"));
                               ^
Added manual change id because file-jpeg.c forced the use of commit -n

Change-Id: Iffff53d6253758c8454d9583f0a11f317c8390cb

Fix warnings/errors of type:
git/epan/dissectors/packet-ax25-kiss.c:205:52: error: 'pseudo_header' was marked unused but was
      used [-Werror,-Wused-but-marked-unused]
                        return capture_ax25( pd, l_offset, len, cpinfo, pseudo_header );

Fix checkhf warnings:
Unused entry: epan/dissectors/packet-artnet.c, hf_artnet_address_netswitch
Unused entry: epan/dissectors/packet-artnet.c, hf_artnet_address_subswitch
Unused entry: epan/dissectors/packet-artnet.c, hf_artnet_poll_reply_trailer
Unused entry: epan/dissectors/packet-artnet.c, hf_artnet_rdm_universe
Unused entry: epan/dissectors/packet-artnet.c, hf_artnet_tod_data_universe

Change-Id: Id1fa12afb97a8e9cd4ed0ea25351c3b2639c930e
Reviewed-on: https://code.wireshark.org/review/14667
Reviewed-by: Jörg Mayer <jmayer@loplof.de>
2016-03-28 12:46:31 +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
Michael Mann 443a7ed259 new_create_dissector_handle -> create_dissector_handle for dissector directory.
Some of the ASN.1 dissectors still generate a new_create_dissector_handle from the tool itself, so leave those for now.

Change-Id: Ic6e5803b1444d7ac24070949f5fd557909a5641f
Reviewed-on: https://code.wireshark.org/review/12484
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-12-09 12:37:36 +00:00
Michael Mann bbdd89b973 create_dissector_handle -> new_create_dissector_handle
Picking off "easy" dissectors that only have one or two exit points at most.

Change-Id: Ie514f126352e7598acc4f7c38db9c61d105d5e48
Reviewed-on: https://code.wireshark.org/review/11850
Petri-Dish: Michael Mann <mmann78@netscape.net>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2015-11-16 03:50:05 +00:00
Dario Lombardo 1b4f96516c Some typos fixed.
Change-Id: I65df0c40d771c4854b73fd5c35d1af600f15f324
Reviewed-on: https://code.wireshark.org/review/6445
Reviewed-by: Pascal Quantin <pascal.quantin@gmail.com>
2015-01-09 14:07:06 +00:00
Bill Meier b5d7b7ab6e Cleanup use of #includes in non-generated epan/dissector/*.c
Specifically:
- Set packet.h to be the first wireshark #include after
   config.h and "system" #includes.
   packet.h added as an #include in some cases when missing.
- Remove some #includes included (directly/indirectly) in
   packet.h. E.g., glib.h.
   (Done only for those files including packet.h).
- As needed, move "system" #includes to be after config.h and
   before wireshark #includes.
- Rework various #include file specifications for consistency.
- Misc.

Change-Id: Ifaa1a14b50b69fbad38ea4838a49dfe595c54c95
Reviewed-on: https://code.wireshark.org/review/5923
Petri-Dish: Alexis La Goutte <alexis.lagoutte@gmail.com>
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-12-21 05:46:22 +00:00
Alexis La Goutte 1cdf644bdb A21: fix warning: no previous prototype for function ... [-Wmissing-prototypes]
Second try... ;-)

Remove also double space

Change-Id: I77aa269c1abae18b4fb9daec6cc0ac862cf4ab9f
Reviewed-on: https://code.wireshark.org/review/5421
Petri-Dish: Anders Broman <a.broman58@gmail.com>
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-11-24 22:03:20 +00:00
Jeff Morriss 1b9dd7547c Fix the build: dissect_a21_ie_common() can't be static any more.
Change-Id: I93db6bc35aef9c36a294e530730cd295ad6851ef
Reviewed-on: https://code.wireshark.org/review/5419
Reviewed-by: Jeff Morriss <jeff.morriss.ws@gmail.com>
2014-11-21 01:31:07 +00:00
Alexis La Goutte 97323982a4 A21: fix warning: no previous prototype for function ... [-Wmissing-prototypes]
Change-Id: Ib2f3816892f1682c175b0dee3c80725caebf3d4d
Reviewed-on: https://code.wireshark.org/review/5415
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-11-20 21:29:36 +00:00
AndersBroman 56fa29edc5 [S1AP] Let the A21 dissector do further dissection of Cdma2000SectorID
Change-Id: I8c503acf6860b34d24769cdf981dcaeea4667ffb
Reviewed-on: https://code.wireshark.org/review/5298
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-11-14 13:57:09 +00:00
Bill Meier 24d50bc290 Adjust indentation to match editor modelines; Do other minor whitespace changes.
Change-Id: Ic020b2c92db5d14a2be9dc4d35aef4514b8b0353
Reviewed-on: https://code.wireshark.org/review/4502
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-10-06 17:12:33 +00:00
AndersBroman 7312c07f8e - Use e212 routine for IMSI.
- Add top_tree to function calls to avoid a crash.
- Set a21_prefs_initialized.

Change-Id: I193ae87189dda9b3806f43c9be3916f1adf7bda2
Reviewed-on: https://code.wireshark.org/review/3902
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-08-28 16:28:34 +00:00
Bill Meier 3ba56cadf0 packet-a21.c: Minor changes
- Comment out several "set but unused" lines of code;
- initialize 'gcsna_handle' only once.

Change-Id: I17a89ccff228b28d075d9db9289ad412892b2639
Reviewed-on: https://code.wireshark.org/review/3837
Reviewed-by: Bill Meier <wmeier@newsguy.com>
2014-08-25 15:28:24 +00:00
Bill Meier c697a86f32 packet-a21.c: Fix a bug; Do some other misc cleanup.
- expert_...() and external dissectors shouldn't be called under 'if (tree)';
- Remove (what appear to be) some unneeded casts;
- (Misc cleanup)

Change-Id: I5ced313d3342125b918e179529b12d2f3bc4d87a
Reviewed-on: https://code.wireshark.org/review/3830
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-08-25 14:00:54 +00:00
Michael Mann 3fa5625ea0 Eliminate proto_tree_add_text from some dissectors.
Change-Id: Ib6024307e85d6c23decf40e9759f549c19ffe136
Reviewed-on: https://code.wireshark.org/review/3318
Petri-Dish: Michael Mann <mmann78@netscape.net>
Petri-Dish: Evan Huus <eapache@gmail.com>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-08-03 16:29:16 +00:00
Michael Mann f5e2b4293d convert to proto_tree_add_subtree[_format]
Change-Id: I358bfaa4e5d40cd01b766f614f8bd0dbaf611dd0
Reviewed-on: https://code.wireshark.org/review/2508
Reviewed-by: Evan Huus <eapache@gmail.com>
Reviewed-by: Michael Mann <mmann78@netscape.net>
2014-06-22 14:34:17 +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
Alexis La Goutte 491a321c37 Fix Dead Store (Dead assignement/Dead increment) warning found by Clang
Change-Id: I35ed4c0ecc28dee57d7a4cac8ddbf43d16b39677
Reviewed-on: https://code.wireshark.org/review/1501
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-05-05 11:19:42 +00:00
Alexis La Goutte 56b8c9e294 Fix indent (use tab) and modelines
Change-Id: Ibff9e0564f2786e8a51b8884724c322725fdf147
Reviewed-on: https://code.wireshark.org/review/1500
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-05-05 11:18:34 +00:00
Michael Mann bf3fbb394f Add dissector for 3GPP2 A21/S102 protocol.
Change-Id: I611c217e1eec47da7427c0317ed9416b4c52411a
Reviewed-on: https://code.wireshark.org/review/1487
Reviewed-by: Anders Broman <a.broman58@gmail.com>
2014-05-05 04:28:57 +00:00