diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-10-21 20:25:55 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-10-24 20:11:20 +0200 |
commit | d7c3e52fbfca2656b361682dca38ae577a10e8b7 (patch) | |
tree | 1e5314789347483a106d1f84067a2d8b9d53d34c /libavutil | |
parent | 9a6cdd1ba3bd6fe592761dc7e9e6b5273495d048 (diff) | |
download | ffmpeg-d7c3e52fbfca2656b361682dca38ae577a10e8b7.tar.gz |
avutil/integer: Use '|' instead of '+' where it is more natural
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavutil')
-rw-r--r-- | libavutil/integer.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/libavutil/integer.c b/libavutil/integer.c index 3bc33dbca2..ae87c467b2 100644 --- a/libavutil/integer.c +++ b/libavutil/integer.c @@ -104,7 +104,7 @@ AVInteger av_shr_i(AVInteger a, int s){ unsigned int index= i + (s>>4); unsigned int v=0; if (index + 1 < AV_INTEGER_SIZE) v = a.v[index + 1] * (1U << 16); - if(index <AV_INTEGER_SIZE) v+= a.v[index ]; + if (index < AV_INTEGER_SIZE) v |= a.v[index]; out.v[i]= v >> (s&15); } return out; @@ -161,6 +161,6 @@ int64_t av_i2int(AVInteger a){ uint64_t out = a.v[3]; for (int i = 2; i >= 0; i--) - out = (out<<16) + a.v[i]; + out = (out << 16) | a.v[i]; return out; } |