avcodec/fitsdec: Use lrint()
authorMichael Niedermayer <michael@niedermayer.cc>
Mon, 30 Sep 2019 16:30:26 +0000 (18:30 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Thu, 5 Dec 2019 19:20:05 +0000 (20:20 +0100)
commit37f31f4e509fe4ccc56a64edaa6fa3d95ee20466
treeef4a1845859fd59eb4b9605f9c118a5014983052
parent4825d8a98d4cddab8710055213e99e47cfd5257a
avcodec/fitsdec: Use lrint()

Fixes: fate-fitsdec-bitpix-64

Possibly Fixes: -nan is outside the range of representable values of type 'unsigned short'
Possibly Fixes: 17769/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_FITS_fuzzer-5678314672357376

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/fitsdec.c
tests/ref/fate/fitsdec-bitpix-32
tests/ref/fate/fitsdec-bitpix-64
tests/ref/fate/fitsdec-blank_bitpix32
tests/ref/fate/fitsdec-ext_data_min_max
tests/ref/fate/fitsdec-gray
tests/ref/lavf/gray16be.fits