Andreas Rheinhardt
a247ac640d
avcodec: Constify AVCodecs
...
Given that the AVCodec.next pointer has now been removed, most of the
AVCodecs are not modified at all any more and can therefore be made
const (as this patch does); the only exceptions are the very few codecs
for external libraries that have a init_static_data callback.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Signed-off-by: James Almer <jamrial@gmail.com>
2021-04-27 10:43:15 -03:00
Michael Niedermayer
5ea7f20500
avcodec/xpmdec: Do not use context dimensions as temporary variables
...
Fixes: Integer overflow
Fixes: 15134/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_XPM_fuzzer-5722635939348480
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2019-06-25 13:30:09 +02:00
Paul B Mahol
03beac5b97
avcodec/xpmdec: define constants
2018-12-10 21:38:08 +01:00
Paul B Mahol
00502370f6
avcodec/xpmdec: fix small artifacts
...
The max size of uint8_t subset is 223 not 220.
2018-12-10 21:31:18 +01:00
Carl Eugen Hoyos
fe300b2ab5
lavc/xpmdec: Allow more colours per character.
...
Fixes ticket #6234 .
2018-12-10 20:59:08 +01:00
Michael Niedermayer
cb243972b1
avcodec/xpmdec: Fix multiple pointer/memory issues
...
Most of these were found through code review in response to
fixing 1466/clusterfuzz-testcase-minimized-5961584419536896
There is thus no testcase for most of this.
The initial issue was Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
2017-05-12 23:38:03 +02:00
James Almer
f5c8d004c2
avcodec: stop using deprecated codec flags
...
Signed-off-by: James Almer <jamrial@gmail.com>
2017-03-25 21:37:05 -03:00
Paul B Mahol
fbfbd97be2
avcodec/xpmdec: there are XPM files with dos line endings
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-13 20:40:41 +01:00
Paul B Mahol
58f0bbc1ea
avcodec/xpmdec: avoid "magic" numbers in function hex_char_to_number()
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
dd0090eb21
avcodec/xpmdec: fix colors values which are different for X11
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
2b790b1c9e
avcodec/xpmdec: do not allow number of colors to be higher than allocated
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
fbc1f323db
avcodec/xpmdec: rename yet another function
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
9d7e71a233
avcodec/xpmdec: rename convert to hex_char_to_number
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
7133ab435a
avcodec/xpmdec: improve comment for one function and also fix 2 identation issues
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 23:03:02 +01:00
Paul B Mahol
e73325b971
avcodec/xpmdec: skip everything before signature
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 18:24:49 +01:00
Paul B Mahol
eda78c8b7f
avcodec/xpmdec: make convert function more picky about its input
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
2017-03-12 18:24:49 +01:00
Paras Chadha
5dab7b91ad
avcodec: add XPM decoder and demuxer
...
Signed-off-by: Paras Chadha <paraschadha18@gmail.com>
2017-03-12 18:24:49 +01:00