diff options
author | Vitaly Novichkov <Wohlstand@users.noreply.github.com> | 2018-04-20 09:58:54 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-20 09:58:54 +0300 |
commit | 726795544abd6a5991d1f610bdb886098a805fb7 (patch) | |
tree | 7f11eae42e4d851e6fb428832dea12f3f0ec2b49 /src/wopl | |
parent | 2c99f0ebc3b2f2cc99b9e7acd8c138921020675d (diff) | |
parent | 9e126007c0e0ffacece64efb436490403dee1493 (diff) | |
download | libADLMIDI-726795544abd6a5991d1f610bdb886098a805fb7.tar.gz libADLMIDI-726795544abd6a5991d1f610bdb886098a805fb7.tar.bz2 libADLMIDI-726795544abd6a5991d1f610bdb886098a805fb7.zip |
Merge pull request #74 from jpcima/fix-rshift
fix implementation defined behavior
Diffstat (limited to 'src/wopl')
-rw-r--r-- | src/wopl/wopl_file.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/wopl/wopl_file.c b/src/wopl/wopl_file.c index 1d4ceeb..af141f2 100644 --- a/src/wopl/wopl_file.c +++ b/src/wopl/wopl_file.c @@ -71,7 +71,7 @@ static void fromUint16BE(uint16_t in, uint8_t *arr) static void fromSint16BE(int16_t in, uint8_t *arr) { arr[1] = in & 0x00FF; - arr[0] = (in >> 8) & 0x00FF; + arr[0] = ((uint16_t)in >> 8) & 0x00FF; } |