summaryrefslogtreecommitdiffstats
path: root/libavformat/rmdec.c
Commit message (Collapse)AuthorAgeFilesLines
* avformat/rmdec: Fix EOF check in the stream loop in ivr_read_header()Michael Niedermayer2018-10-071-0/+2
| | | | | | | | | | | Fixes: long running loop Fixes: ivr-timeout-42468cb797f52f025fb329394702f5d4d64322d6 Found-by: Paul Ch <[email protected]> Reviewed-by: Paul B Mahol <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]> (cherry picked from commit c2eec1762d372663c35aaf3d6ee419bafb185057) Signed-off-by: Michael Niedermayer <[email protected]>
* avformat/rmdec: Do not pass mime type in rm_read_multi() to ↵Michael Niedermayer2018-07-161-1/+1
| | | | | | | | | | | | ff_rm_read_mdpr_codecdata() Fixes: use after free() Fixes: rmdec-crash-ffe85b4cab1597d1cfea6955705e53f1f5c8a362 Found-by: Paul Ch <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]> (cherry picked from commit a7e032a277452366771951e29fd0bf2bd5c029f0) Signed-off-by: Michael Niedermayer <[email protected]>
* avformat/rmdec: make use of avio_get_str()Paul B Mahol2018-04-021-11/+7
| | | | | | Also do not set empty metadata. Signed-off-by: Paul B Mahol <[email protected]>
* Merge commit '95ce02b35d3d1bb16111031df1d82a6e4d894d36'James Almer2017-11-071-4/+7
|\ | | | | | | | | | | | | | | | | * commit '95ce02b35d3d1bb16111031df1d82a6e4d894d36': rmdec: don't ignore the return value of av_get_packet() See 65b83ce01b94eae944290c11257799a9288f2d4c Merged-by: James Almer <[email protected]>
| * rmdec: don't ignore the return value of av_get_packet()Sean McGovern2017-07-171-5/+14
| |
| * Use correct printf conversion specifiers for POSIX integer typesDiego Biurrun2016-12-231-1/+1
| |
* | avformat/rmdec: Fix DoS due to lack of eof check孙浩 and 张洪亮(望初)2017-08-271-1/+4
| | | | | | | | | | | | | | Fixes: loop.ivr Found-by: Xiaohei and Wangchu from Alibaba Security Team Signed-off-by: Michael Niedermayer <[email protected]>
* | Fix all -Wformat warnings raised by DJGPPClément Bœsch2017-03-291-1/+2
| |
* | lavf: use av_fourcc2str() where appropriateClément Bœsch2017-03-291-7/+2
| |
* | Merge commit '83548fe894cdb455cc127f754d09905b6d23c173'James Almer2017-03-211-1/+2
|\| | | | | | | | | | | | | * commit '83548fe894cdb455cc127f754d09905b6d23c173': lavf: fix usage of AVIOContext.seekable Merged-by: James Almer <[email protected]>
| * lavf: fix usage of AVIOContext.seekableAnton Khirnov2016-09-301-1/+2
| | | | | | | | | | | | | | | | It is supposed to be a flag. The only currently defined value is AVIO_SEEKABLE_NORMAL, but other ones may be added in the future. However all the current lavf code treats this field as a bool (mainly for historical reasons). Change all those cases to properly check for AVIO_SEEKABLE_NORMAL.
* | Merge commit 'd9442d13033a24b14ebae149dcdb42709430e2d9'Clément Bœsch2017-03-191-13/+0
|\| | | | | | | | | | | | | * commit 'd9442d13033a24b14ebae149dcdb42709430e2d9': rm: Drop broken disabled cruft Merged-by: Clément Bœsch <[email protected]>
| * rm: Drop broken disabled cruftDiego Biurrun2016-08-171-13/+0
| |
* | avcodec: add SIPR parserPaul B Mahol2017-01-161-0/+1
| | | | | | | | | | | | Fixes #2056. Signed-off-by: Paul B Mahol <[email protected]>
* | rmdec: validate block alignmentAndreas Cadhalpun2016-11-231-0/+4
| | | | | | | | | | | | | | This fixes division by zero crashes. Reviewed-by: Michael Niedermayer <[email protected]> Signed-off-by: Andreas Cadhalpun <[email protected]>
* | lavf/rmdec: Do not return EIO on EOF.Carl Eugen Hoyos2016-08-021-1/+3
| | | | | | | | Reported-by: applemax82
* | avformat/rmdec: Clear extradata when extradata_size is clearedMichael Niedermayer2016-07-291-0/+1
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat: add AVFormatContext to ff_get_extradata()Paul B Mahol2016-04-141-1/+1
| | | | | | | | | | | | Needed for av_log() inside that function. Signed-off-by: Paul B Mahol <[email protected]>
* | Merge commit '9200514ad8717c63f82101dc394f4378854325bf'Derek Buitenhuis2016-04-101-59/+59
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '9200514ad8717c63f82101dc394f4378854325bf': lavf: replace AVStream.codec with AVStream.codecpar This has been a HUGE effort from: - Derek Buitenhuis <[email protected]> - Hendrik Leppkes <[email protected]> - wm4 <[email protected]> - Clément Bœsch <[email protected]> - James Almer <[email protected]> - Michael Niedermayer <[email protected]> - Rostislav Pehlivanov <[email protected]> Merged-by: Derek Buitenhuis <[email protected]>
| * lavf: replace AVStream.codec with AVStream.codecparAnton Khirnov2016-02-231-57/+57
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Currently, AVStream contains an embedded AVCodecContext instance, which is used by demuxers to export stream parameters to the caller and by muxers to receive stream parameters from the caller. It is also used internally as the codec context that is passed to parsers. In addition, it is also widely used by the callers as the decoding (when demuxer) or encoding (when muxing) context, though this has been officially discouraged since Libav 11. There are multiple important problems with this approach: - the fields in AVCodecContext are in general one of * stream parameters * codec options * codec state However, it's not clear which ones are which. It is consequently unclear which fields are a demuxer allowed to set or a muxer allowed to read. This leads to erratic behaviour depending on whether decoding or encoding is being performed or not (and whether it uses the AVStream embedded codec context). - various synchronization issues arising from the fact that the same context is used by several different APIs (muxers/demuxers, parsers, bitstream filters and encoders/decoders) simultaneously, with there being no clear rules for who can modify what and the different processes being typically delayed with respect to each other. - avformat_find_stream_info() making it necessary to support opening and closing a single codec context multiple times, thus complicating the semantics of freeing various allocated objects in the codec context. Those problems are resolved by replacing the AVStream embedded codec context with a newly added AVCodecParameters instance, which stores only the stream parameters exported by the demuxers or read by the muxers.
* | avcodec/rmdec: add missing av_log argumentJames Almer2016-01-151-1/+1
| | | | | | | | | | | | Also change the format specifier to expect an unsigned int Signed-off-by: James Almer <[email protected]>
* | avformat/rmdec: Fix Packet memleak at close()Michael Niedermayer2016-01-141-0/+1
| | | | | | | | | | | | | | Fixes: asan_heap-oob_445b39_1741_d00eb645ab48eb2203b4a04a5b997103.ivr Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/rmdec: Check size in ivr_read_packet() before useMichael Niedermayer2016-01-141-0/+5
| | | | | | | | | | | | | | | | Fixes out of array access Fixes: asan_heap-oob_445b39_1741_d00eb645ab48eb2203b4a04a5b997103.ivr Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind Signed-off-by: Michael Niedermayer <[email protected]>
* | lavf/rmdec: Use correct format specifier for int64_t.Carl Eugen Hoyos2015-12-221-1/+1
| | | | | | | | Fixes ticket #5100.
* | avformat/rmdec: Fix use of uninitialized variableMichael Niedermayer2015-12-091-1/+1
| | | | | | | | | | | | Fixes: CID1341580 Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat: add IVR demuxerPaul B Mahol2015-11-181-34/+275
| | | | | | | | Signed-off-by: Paul B Mahol <[email protected]>
* | Replace remaining occurances of av_free_packet with av_packet_unrefHendrik Leppkes2015-10-271-1/+1
| |
* | Merge commit 'ce70f28a1732c74a9cd7fec2d56178750bd6e457'Hendrik Leppkes2015-10-271-3/+3
|\| | | | | | | | | | | | | * commit 'ce70f28a1732c74a9cd7fec2d56178750bd6e457': avpacket: Replace av_free_packet with av_packet_unref Merged-by: Hendrik Leppkes <[email protected]>
| * avpacket: Replace av_free_packet with av_packet_unrefLuca Barbato2015-10-261-3/+3
| | | | | | | | | | | | | | `av_packet_unref` matches the AVFrame ref-counted API and can be used as a drop in replacement. Deprecate `av_free_packet`.
* | Merge commit '01bcc2d5c23fa757d163530abb396fd02f1be7c8'Hendrik Leppkes2015-09-051-5/+0
|\| | | | | | | | | | | | | * commit '01bcc2d5c23fa757d163530abb396fd02f1be7c8': lavc: Drop deprecated destruct_packet related functions Merged-by: Hendrik Leppkes <[email protected]>
| * lavc: Drop deprecated destruct_packet related functionsVittorio Giovara2015-08-281-5/+0
| | | | | | | | Deprecated in 10/2012.
* | avformat/rmdec: MLTI with multiple MDPR supportMichael Niedermayer2015-08-141-8/+38
| | | | | | | | | | | | Fixes Ticket4496 Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/rmdec: Move MLTI handling out of ff_rm_read_mdpr_codecdata()Michael Niedermayer2015-08-141-15/+22
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit '059a934806d61f7af9ab3fd9f74994b838ea5eba'Michael Niedermayer2015-07-271-2/+2
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '059a934806d61f7af9ab3fd9f74994b838ea5eba': lavc: Consistently prefix input buffer defines Conflicts: doc/examples/decoding_encoding.c libavcodec/4xm.c libavcodec/aac_adtstoasc_bsf.c libavcodec/aacdec.c libavcodec/aacenc.c libavcodec/ac3dec.h libavcodec/asvenc.c libavcodec/avcodec.h libavcodec/avpacket.c libavcodec/dvdec.c libavcodec/ffv1enc.c libavcodec/g2meet.c libavcodec/gif.c libavcodec/h264.c libavcodec/h264_mp4toannexb_bsf.c libavcodec/huffyuvdec.c libavcodec/huffyuvenc.c libavcodec/jpeglsenc.c libavcodec/libxvid.c libavcodec/mdec.c libavcodec/motionpixels.c libavcodec/mpeg4videodec.c libavcodec/mpegvideo.c libavcodec/noise_bsf.c libavcodec/nuv.c libavcodec/nvenc.c libavcodec/options.c libavcodec/parser.c libavcodec/pngenc.c libavcodec/proresenc_kostya.c libavcodec/qsvdec.c libavcodec/svq1enc.c libavcodec/tiffenc.c libavcodec/truemotion2.c libavcodec/utils.c libavcodec/utvideoenc.c libavcodec/vc1dec.c libavcodec/wmalosslessdec.c libavformat/adxdec.c libavformat/aiffdec.c libavformat/apc.c libavformat/apetag.c libavformat/avidec.c libavformat/bink.c libavformat/cafdec.c libavformat/flvdec.c libavformat/id3v2.c libavformat/isom.c libavformat/matroskadec.c libavformat/mov.c libavformat/mpc.c libavformat/mpc8.c libavformat/mpegts.c libavformat/mvi.c libavformat/mxfdec.c libavformat/mxg.c libavformat/nutdec.c libavformat/oggdec.c libavformat/oggparsecelt.c libavformat/oggparseflac.c libavformat/oggparseopus.c libavformat/oggparsespeex.c libavformat/omadec.c libavformat/rawdec.c libavformat/riffdec.c libavformat/rl2.c libavformat/rmdec.c libavformat/rtpdec_latm.c libavformat/rtpdec_mpeg4.c libavformat/rtpdec_qdm2.c libavformat/rtpdec_svq3.c libavformat/sierravmd.c libavformat/smacker.c libavformat/smush.c libavformat/spdifenc.c libavformat/takdec.c libavformat/tta.c libavformat/utils.c libavformat/vqf.c libavformat/westwood_vqa.c libavformat/xmv.c libavformat/xwma.c libavformat/yop.c Merged-by: Michael Niedermayer <[email protected]>
| * lavc: Consistently prefix input buffer definesVittorio Giovara2015-07-271-3/+3
| | | | | | | | Signed-off-by: Vittorio Giovara <[email protected]>
* | Merge commit '1a3eb042c704dea190c644def5b32c9cee8832b8'Michael Niedermayer2015-04-201-3/+3
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit '1a3eb042c704dea190c644def5b32c9cee8832b8': Replace av_dlog with normal av_log at trace level Conflicts: ffplay.c libavdevice/fbdev_dec.c libavfilter/avfilter.c libavfilter/internal.h libavfilter/setpts.c libavfilter/src_movie.c libavfilter/vf_crop.c libavfilter/vf_drawtext.c libavfilter/vf_fieldorder.c libavformat/assdec.c libavformat/avidec.c libavformat/flvdec.c libavformat/http.c libavformat/ipmovie.c libavformat/isom.c libavformat/mov.c libavformat/mpegenc.c libavformat/mpegts.c libavformat/mpegtsenc.c libavformat/mux.c libavformat/mxfdec.c libavformat/nsvdec.c libavformat/oggdec.c libavformat/r3d.c libavformat/rtspdec.c libavformat/utils.c Merged-by: Michael Niedermayer <[email protected]>
| * Replace av_dlog with normal av_log at trace levelVittorio Giovara2015-04-191-3/+3
| | | | | | | | This applies to every library where performance is not critical.
| * rmdec: Improve message for demux errorCarl Eugen Hoyos2015-03-081-1/+1
| | | | | | | | | | | | | | Use correct context, reduce log level, don't assume it is a video stream, and print the tag of the unknown stream. Signed-off-by: Vittorio Giovara <[email protected]>
* | avformat/rmdec: fix support for 0 sized mdprMichael Niedermayer2015-03-261-0/+2
| | | | | | | | | | | | Fixes Ticket4393 Signed-off-by: Michael Niedermayer <[email protected]>
* | fix spelling errorsAndreas Cadhalpun2015-03-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | opttimizations -> optimizations grabing -> grabbing many resource -> many resources isnt -> isn't silcense -> silence Signed-off-by: Andreas Cadhalpun <[email protected]> Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit 'da7e31a240f276836a0b90ca6c0714181b353cc4'Michael Niedermayer2015-02-171-0/+6
|\| | | | | | | | | | | | | * commit 'da7e31a240f276836a0b90ca6c0714181b353cc4': rmdec: Check memory allocations from ff_rm_alloc_rmstream() Merged-by: Michael Niedermayer <[email protected]>
| * rmdec: Check memory allocations from ff_rm_alloc_rmstream()Hugo Beauzée-Luyssen2015-02-171-0/+6
| | | | | | | | Bug-Id: CID 1257835
* | Merge commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e'Michael Niedermayer2015-02-141-1/+1
|\| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * commit 'daf8cf358a098a903d59adb6c0d0cc3262a8c93e': avformat: Don't anonymously typedef structs Conflicts: libavformat/adtsenc.c libavformat/aiffenc.c libavformat/avidec.c libavformat/gif.c libavformat/iff.c libavformat/img2dec.c libavformat/jvdec.c libavformat/matroskadec.c libavformat/udp.c libavformat/wtvdec.c Merged-by: Michael Niedermayer <[email protected]>
| * avformat: Don't anonymously typedef structsDiego Biurrun2015-02-141-1/+1
| |
* | avformat/rmdec: Check the return value of av_get_packet()Michael Niedermayer2015-01-181-6/+11
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | rm: fix memory leak on init failurewm42015-01-101-5/+14
| | | | | | | | | | | | | | AVInputFormat.read_close is not called if AVInputFormat.read_header fails, so this needs to be handled separately. Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/rmdec: Check for overflow in ff_rm_read_mdpr_codecdata()Michael Niedermayer2014-12-061-1/+5
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | avformat/rmdec: rm_read_extradata: add error message for oversized extradataMichael Niedermayer2014-12-061-1/+3
| | | | | | | | Signed-off-by: Michael Niedermayer <[email protected]>
* | Merge commit '1c77ead1fb14d64e6798fc5e32af04abcb3cebb4'Michael Niedermayer2014-12-061-4/+4
|\| | | | | | | | | | | | | | | | | | | | | | | * commit '1c77ead1fb14d64e6798fc5e32af04abcb3cebb4': rm: Use the correct codec_data_size signedness Conflicts: libavformat/rm.h libavformat/rmdec.c See: a6f730730b82645a9d31aad0968487cb77d6946c Merged-by: Michael Niedermayer <[email protected]>
| * rm: Use the correct codec_data_size signednessLuca Barbato2014-12-041-3/+3
| | | | | | | | | | | | | | | | | | The function takes a size and not an offset. CC: [email protected] Sample-Id: rm_deadlock.rm Signed-off-by: Luca Barbato <[email protected]>