diff options
author | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-03-28 13:44:50 +0100 |
---|---|---|
committer | Francois-Xavier Le Bail <devel.fx.lebail@orange.fr> | 2019-03-28 14:13:27 +0100 |
commit | 400643120a48eca33973f6a47b34f0dcfde4d20a (patch) | |
tree | 1b13f95a009e86c6e4fbb3249f03177e0b83b508 /print-isakmp.c | |
parent | f280b3c0dfb5200512ebb03b1e9b7e2ab868dd5b (diff) | |
download | tcpdump-400643120a48eca33973f6a47b34f0dcfde4d20a.tar.gz |
IEEE 802.15.4: Fix an undefined behavior at runtime
The error was:
print-802_15_4.c:442:9: runtime error: implicit conversion from type
'int' of value 15840046 (32-bit, signed) to type 'uint16_t' (aka
'unsigned short') changed the value to 45870 (16-bit, unsigned)
Proposal of fix by Guy Harris:
"Those shifted values will be converted (in the C abstract machine) to
int, but they'll all be in the range 0 to 65535, as will be the XOR of
all 4 of them; converting that to a uint16_t isn't undefined behavior."
Diffstat (limited to 'print-isakmp.c')
0 files changed, 0 insertions, 0 deletions