diff options
author | Luke Berndt <lukekb@gmail.com> | 2023-05-04 13:42:32 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-05-04 13:42:32 -0400 |
commit | 03422091e193e19c7eccbfeb91967bef115d52d4 (patch) | |
tree | bbc163f065ca770a996adbc273901ecba0a84fce | |
parent | bf5281a3dfb32f36d7ba5938a99ace43e2685bd8 (diff) | |
parent | e7ad3f481373f752f5a4109bbb98f1c54f1f2502 (diff) |
Merge pull request #802 from taclane/neg-offset-fix
Fix freq offset variable declarations in trunking messages
-rw-r--r-- | trunk-recorder/systems/p25_parser.cc | 2 | ||||
-rw-r--r-- | trunk-recorder/systems/p25_parser.h | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/trunk-recorder/systems/p25_parser.cc b/trunk-recorder/systems/p25_parser.cc index 619cdd8c..4f12e4fd 100644 --- a/trunk-recorder/systems/p25_parser.cc +++ b/trunk-recorder/systems/p25_parser.cc @@ -847,7 +847,7 @@ std::vector<TrunkMessage> P25Parser::decode_tsbk(boost::dynamic_bitset<> &tsbk, unsigned long spac = bitset_shift_mask(tsbk, 48, 0x3ff); unsigned long freq = bitset_shift_mask(tsbk, 16, 0xffffffff); unsigned long toff_sign = (toff0 >> 8) & 1; - unsigned long toff = toff0 & 0xff; + long toff = toff0 & 0xff; if (toff_sign == 0) { toff = 0 - toff; diff --git a/trunk-recorder/systems/p25_parser.h b/trunk-recorder/systems/p25_parser.h index 0537df73..f92c8137 100644 --- a/trunk-recorder/systems/p25_parser.h +++ b/trunk-recorder/systems/p25_parser.h @@ -12,7 +12,7 @@ struct Channel { unsigned long id; - unsigned long offset; + long offset; unsigned long step; unsigned long frequency; bool phase2_tdma; |