URL: https://code.wireshark.org/review/gitweb?p=wireshark.git;a=commit;h=b84972635117aa5cac7f8e6296d07ceb51bfe5e2
Submitter: Guy Harris (guy@xxxxxxxxxxxx)
Changed: branch: master
Repository: wireshark
Commits:
b849726 by Guy Harris (guy@xxxxxxxxxxxx):
Fix some cases where we're shifting a signed 1 left.
Shift 1U instead, to make sure it's unsigned; the result of, for
example, the result of shifting a signed value left is undefined if the
value times 2^{shift count} doesn't fit in the *signed* type of the
shifted value. That means, in particular, that the result of shifting 1
left by {number of bits in an int - 1} is undefined. (In *practice*,
it'll probably be -2^32, with the bit you want set, but that's not
guaranteed, and GCC 5.1 seems not to like it.)
Make some other left-hand operands of <<, and some variables holding
results from shifts of that sort, unsigned, while we're at it.
Change-Id: Ie72a9d0d518f59b35948267d10c80735d162e8bb
Reviewed-on: https://code.wireshark.org/review/8264
Reviewed-by: Guy Harris <guy@xxxxxxxxxxxx>
Actions performed:
from 91515a0 Add tshark -z "ncp,srt"
adds b849726 Fix some cases where we're shifting a signed 1 left.
Summary of changes:
asn1/ess/packet-ess-template.c | 2 +-
asn1/ranap/packet-ranap-template.c | 6 +++---
asn1/rrc/rrc.cnf | 16 +++++++-------
asn1/sv/packet-sv-template.c | 42 ++++++++++++++++++------------------
epan/dissectors/packet-ess.c | 2 +-
epan/dissectors/packet-ranap.c | 6 +++---
epan/dissectors/packet-rrc.c | 16 +++++++-------
epan/dissectors/packet-sv.c | 42 ++++++++++++++++++------------------
8 files changed, 66 insertions(+), 66 deletions(-)