]> git.sesse.net Git - ffmpeg/commit
libavcodec/iff: Use unsigned to avoid undefined behaviour
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Fri, 2 Aug 2019 20:29:16 +0000 (22:29 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Mon, 5 Aug 2019 15:54:24 +0000 (17:54 +0200)
commitf12e662a3d3f489eec887b5f2ab20a550caed9cf
tree04b2a68049f8fb1ca92c89ed83eb2179b852c9a9
parent43015afd7ce9055f1fa2d7648c3fcd9b7cfd7721
libavcodec/iff: Use unsigned to avoid undefined behaviour

The initialization of the uint32_t plane32_lut matrix uses left shifts
of the form 1 << plane; plane can be as big as 31 which means that this
is undefined behaviour as 1 will be simply an int. So make it unsigned
to avoid this.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/iff.c