diff options
author | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2021-02-14 22:24:46 +0100 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@gmail.com> | 2021-02-14 22:47:08 +0100 |
commit | 9c0b3eddf4262f9dcea479091f1307444e614e88 (patch) | |
tree | 280eda6bb997a441a7576188b55b7bc6934f4576 /libavcodec/pnmdec.c | |
parent | 4f49ca7bbc75a9db4cdf93f27f95a668c751f160 (diff) | |
download | ffmpeg-9c0b3eddf4262f9dcea479091f1307444e614e88.tar.gz |
avformat/utils: Fix undefined NULL + 0
This is undefined behaviour in C, so use data = len ? data + len : data
instead of data += len. GCC optimizes the branch away in this case;
Clang unfortunately doesn't.
Fixes ticket #8592.
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/pnmdec.c')
0 files changed, 0 insertions, 0 deletions