diff options
author | Guy Harris <guy@alum.mit.edu> | 2018-10-29 15:22:38 -0700 |
---|---|---|
committer | Guy Harris <guy@alum.mit.edu> | 2018-10-29 22:23:12 +0000 |
commit | 6177f0eb42a1da2d8241733d1d0eb699c8785d3c (patch) | |
tree | 7aea03c73a350d123a1e602f2f9170a26031b68f /epan/dissectors/packet-ieee80211-radio.c | |
parent | b6fe64017a967ee95eaafe3751ebb0738d1c5737 (diff) |
The signal strength and noise in dB from an arbitrary reference are unsigned.
The radiotap spec says "dB antenna signal" and "dB antenna noise" are
unsigned. Make it universally so.
Change-Id: Iea2c5360d7352ca5e84862ea338d1fc689272191
Reviewed-on: https://code.wireshark.org/review/30410
Reviewed-by: Guy Harris <guy@alum.mit.edu>
Diffstat (limited to 'epan/dissectors/packet-ieee80211-radio.c')
-rw-r--r-- | epan/dissectors/packet-ieee80211-radio.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/epan/dissectors/packet-ieee80211-radio.c b/epan/dissectors/packet-ieee80211-radio.c index fdb4efdf0b..caea617603 100644 --- a/epan/dissectors/packet-ieee80211-radio.c +++ b/epan/dissectors/packet-ieee80211-radio.c @@ -861,8 +861,8 @@ dissect_wlan_radio_phdr(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, } if (phdr->has_signal_db) { - col_add_fstr(pinfo->cinfo, COL_RSSI, "%d dB", phdr->signal_db); - proto_tree_add_int(radio_tree, hf_wlan_radio_signal_db, tvb, 0, 0, phdr->signal_db); + col_add_fstr(pinfo->cinfo, COL_RSSI, "%u dB", phdr->signal_db); + proto_tree_add_uint(radio_tree, hf_wlan_radio_signal_db, tvb, 0, 0, phdr->signal_db); } if (phdr->has_signal_dbm) { @@ -875,7 +875,7 @@ dissect_wlan_radio_phdr(tvbuff_t * tvb, packet_info * pinfo, proto_tree * tree, } if (phdr->has_noise_db) { - proto_tree_add_int(radio_tree, hf_wlan_radio_noise_db, tvb, 0, 0, phdr->noise_db); + proto_tree_add_uint(radio_tree, hf_wlan_radio_noise_db, tvb, 0, 0, phdr->noise_db); } if (phdr->has_noise_dbm) { @@ -1413,7 +1413,7 @@ void proto_register_ieee80211_radio(void) "Signal strength, as percentage of maximum RSSI", HFILL }}, {&hf_wlan_radio_signal_db, - {"Signal strength (dB)", "wlan_radio.signal_db", FT_INT8, BASE_DEC|BASE_UNIT_STRING, &units_decibels, 0, + {"Signal strength (dB)", "wlan_radio.signal_db", FT_UINT8, BASE_DEC|BASE_UNIT_STRING, &units_decibels, 0, NULL, HFILL }}, {&hf_wlan_radio_signal_dbm, @@ -1425,7 +1425,7 @@ void proto_register_ieee80211_radio(void) NULL, HFILL }}, {&hf_wlan_radio_noise_db, - {"Noise level (dB)", "wlan_radio.noise_db", FT_INT8, BASE_DEC|BASE_UNIT_STRING, &units_decibels, 0, + {"Noise level (dB)", "wlan_radio.noise_db", FT_UINT8, BASE_DEC|BASE_UNIT_STRING, &units_decibels, 0, NULL, HFILL }}, {&hf_wlan_radio_noise_dbm, |