diff options
author | Colin Ian King <colin.king@canonical.com> | 2019-01-15 19:03:38 +0100 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2019-01-17 20:27:00 +0100 |
commit | cb12d72b27a6f41325ae23a11033cf5fedfa1b97 (patch) | |
tree | 766c9eab37443392f4603bc802e8fe88c960830f /drivers/pci/syscall.c | |
parent | udp: with udp_segment release on error path (diff) | |
download | linux-cb12d72b27a6f41325ae23a11033cf5fedfa1b97.tar.xz linux-cb12d72b27a6f41325ae23a11033cf5fedfa1b97.zip |
atm: he: fix sign-extension overflow on large shift
Shifting the 1 by exp by an int can lead to sign-extension overlow when
exp is 31 since 1 is an signed int and sign-extending this result to an
unsigned long long will set the upper 32 bits. Fix this by shifting an
unsigned long.
Detected by cppcheck:
(warning) Shifting signed 32-bit value by 31 bits is undefined behaviour
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/pci/syscall.c')
0 files changed, 0 insertions, 0 deletions