Diego Biurrun
daf8cf358a
avformat: Don't anonymously typedef structs
10 years ago
Paul B Mahol
c099783316
avformat/nsvdec: remove case which is no longer possible
...
Check of channels !=0 is right above.
Signed-off-by: Paul B Mahol <onemda@gmail.com>
10 years ago
Vittorio Giovara
7c51d79ca7
nsvdec: validate channels and samplerate
...
Avoid a division by zero.
CC: libav-stable@libav.org
Bug-Id: CID 717749
10 years ago
Michael Niedermayer
8d7ce5cdb7
avformat/nsvdec: Check the return value of av_get_packet()
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
edf1cb7aee
avformat/nsvdec: Check av_get_packet() return value
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Michael Niedermayer
bf16872fec
avformat/nsvdec: fix out-commented asserts so the function names exist
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Gabriel Dume
f929ab0569
cosmetics: Write NULL pointer equality checks more compactly
...
Signed-off-by: Diego Biurrun <diego@biurrun.de>
10 years ago
James Almer
d34ec64a22
replace calls to url_feof() with avio_feof()
...
Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
10 years ago
Anton Khirnov
27c1f82f56
nsvdec: remove commented out cruft
11 years ago
Diego Biurrun
9f84ed8cc3
nsvdec: Remove commented-out debug cruft
12 years ago
Diego Biurrun
e0f8be6413
avformat: Add AVPROBE_SCORE_EXTENSION define and use where appropriate
12 years ago
Diego Biurrun
ac9362c5d9
Move misplaced file author information where it belongs
12 years ago
Diego Biurrun
523c7bd23c
misc typo, style and wording fixes
12 years ago
Justin Ruggles
bfe5454cd2
lavf: move ff_codec_get_tag() and ff_codec_get_id() definitions to internal.h
12 years ago
Michael Niedermayer
d633e15d7d
nsvdec: fix division by 0
...
Fixes CID717749
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Michael Niedermayer
a1fb2b935a
nsvdec: change 2 commented assert() to av_assert()
...
they keep showing up if i grep for non av assert()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
12 years ago
Anton Khirnov
36ef5369ee
Replace all CODEC_ID_* with AV_CODEC_ID_*
12 years ago
Diego Biurrun
30b1961c66
Mark a number of variables only used in av_dlog() calls as av_unused.
...
This fixes a number of unused-but-set gcc warnings.
13 years ago
Diego Biurrun
6df5c528ca
Move some conditionally used variables into the block where they are used.
...
This allows dropping the av_unused argument from them.
13 years ago
Diego Biurrun
7331b6e718
Drop some completely unnecessary av_unused attributes.
13 years ago
Joakim Plate
8dcd00eabd
nsvdec: Check return value of avio_seek and avoid modifying state if it fails
...
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Justin Ruggles <justin.ruggles@gmail.com>
13 years ago
Alex Converse
c898431ca5
nsvdec: Propagate errors
...
Related to CVE-2011-3940.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
13 years ago
Alex Converse
8fd8a48263
nsvdec: Be more careful with av_malloc().
...
Check results for av_malloc() and fix an overflow in one call.
Related to CVE-2011-3940.
Based in part on work from Michael Niedermayer.
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
13 years ago
Michael Niedermayer
6a89b41d97
nsvdec: Fix use of uninitialized streams.
...
Fixes CVE-2011-3940 (Out of bounds read resulting in out of bounds write)
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5c011706bc
)
Signed-off-by: Alex Converse <alex.converse@gmail.com>
13 years ago
Anton Khirnov
6e9651d106
lavf: remove AVFormatParameters from AVFormatContext.read_header signature
13 years ago
Michael Niedermayer
5c011706bc
nsvdec: Fix use of uninitialized streams.
...
Fixes CVE-2011-3940 (Out of bounds read resulting in out of bounds write)
Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Michael Niedermayer
b9e0e9537a
nsvdec: Check av_malloc(string_size)
...
This can easily be NULL as string_size can be 2g in a damaged file.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
13 years ago
Reimar Döffinger
36be045ed7
Support "VLB " audio in NSV files.
...
See samples/nsv/vlb_audio.
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
13 years ago
Reimar Döffinger
c3068d43a8
Support VP8 in NSV.
...
Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
13 years ago
Anton Khirnov
c3f9ebf743
lavf: make av_set_pts_info private.
...
It's supposed to be called only from (de)muxers.
13 years ago
Diego Biurrun
20566eb0f0
Replace outdated references to ffmpeg tool with avconv.
13 years ago
Anton Khirnov
84ad31ff18
lavf: replace av_new_stream->avformat_new_stream part II.
...
Manual replacements are done in this commit.
In many cases, the id is some constant made up number (e.g. 0 for video
and 1 for audio), which is then not used in the demuxer for anything.
Those ids are removed.
13 years ago
Joakim Plate
e22155ef0e
[nsv] Check return value of avio_seek and avoid modifying state if it fails
13 years ago
Anton Khirnov
dfc2c4d900
lavf: use designated initialisers for all (de)muxers.
...
It's more readable and less prone to breakage.
14 years ago
Mans Rullgard
0ebcdf5cda
Do not include mathematics.h in avutil.h
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Diego Biurrun
35fa0d4758
nsvdec: Propagate error values instead of returning 0 in nsv_read_header().
...
This eliminates a warning about a set-but-unused variable.
14 years ago
Aurelien Jacobs
eb8de45c3c
nsv: simplify probe function
14 years ago
Aurelien Jacobs
223694b404
nsv: return error code instead of discarding it in read_header()
14 years ago
Diego Biurrun
919d7a345a
Replace DEBUG_SEEK/DEBUG_SI + av_log combinations by av_dlog.
14 years ago
Anton Khirnov
d2d67e424f
Remove all uses of now deprecated metadata functions.
14 years ago
Mans Rullgard
5e1166b31b
Mark some variables with av_unused
...
Most of these variables are only used in av_dlog statements, some
are required but not used by other macros.
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Thierry Foucu
b7903ab16b
If a MP3 file contains the string NSVs, the NSV probe will think it is a NSV file instead of a MP3 file. Check for 0xBEEF after a Video/Audio chunck for more accuracy.
...
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
14 years ago
Thierry Foucu
45faf7fcd3
nsv: Fix misdetection of MP3 files as NSV.
...
If an MP3 file contains the string NSVs, the NSV probe will confuse it for an
NSV file. Check for 0xBEEF after a Video/Audio chunk to achieve more accuracy.
Signed-off-by: Diego Biurrun <diego@biurrun.de>
14 years ago
Mans Rullgard
2912e87a6c
Replace FFmpeg with Libav in licence headers
...
Signed-off-by: Mans Rullgard <mans@mansr.com>
14 years ago
Anton Khirnov
45a8a02a41
lavf: replace avio_seek(SEEK_CUR) with avio_skip where it makes sense
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
66e5b1df36
avio: deprecate url_feof
...
AVIOContext.eof_reached should be used directly instead.
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
384c9c2fa7
avio: add avio_tell macro as a replacement for url_ftell
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit a2704c9712
)
14 years ago
Anton Khirnov
a2704c9712
avio: add avio_tell macro as a replacement for url_ftell
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
14 years ago
Anton Khirnov
74b3f67c9c
lavf: replace all uses of url_fskip with avio_seek
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit e356fc57a2
)
14 years ago
Anton Khirnov
f59d8ff8cd
avio: avio_ prefix for url_fseek
...
Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit 6b4aa5dac8
)
14 years ago