ffmpeg.git
6 years agoupdate for 0.11.3 n0.11.3
Michael Niedermayer [Fri, 22 Mar 2013 03:05:35 +0000 (04:05 +0100)]
update for 0.11.3

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoupdate the current year
Michael Niedermayer [Thu, 21 Mar 2013 00:10:47 +0000 (01:10 +0100)]
update the current year

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit f2310fff5c7bf1ec815ba7ae6a87fc872a0d82aa)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoMAINTAINERS: mention that people are welcome to pick up and maintain older releases
Michael Niedermayer [Thu, 14 Mar 2013 13:50:42 +0000 (14:50 +0100)]
MAINTAINERS: mention that people are welcome to pick up and maintain older releases

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 7e1efeb5707ec0fec000d42fa9f2861bab97bd8f)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoMAINTAINERS: update for 1.2
Michael Niedermayer [Fri, 8 Mar 2013 13:45:26 +0000 (14:45 +0100)]
MAINTAINERS: update for 1.2

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 80f91a70be5f03fc95eb89d222d760eeaf91b135)

Conflicts:

MAINTAINERS

6 years agormdec: flush audio packet on seeking
Michael Niedermayer [Sun, 17 Mar 2013 23:00:02 +0000 (00:00 +0100)]
rmdec: flush audio packet on seeking

Fixes Ticket1605

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 519ebb5ee5b89b8ecc80b4a4540fcbeb65cda172)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoMerge remote-tracking branch 'jamrial/release/0.11' into release/0.11
Michael Niedermayer [Wed, 20 Mar 2013 21:10:34 +0000 (22:10 +0100)]
Merge remote-tracking branch 'jamrial/release/0.11' into release/0.11

* jamrial/release/0.11:
  lavc/bink: Chech for malloc failure

Merged-by: Michael Niedermayer <michaelni@gmx.at>
6 years agomp3dec: Fix VBR bit rate parsing
Alexander Kojevnikov [Wed, 27 Feb 2013 05:47:11 +0000 (21:47 -0800)]
mp3dec: Fix VBR bit rate parsing

When parsing the Xing/Info tag, don't set the bit rate if it's an Info tag.

When parsing the stream, don't override the bit rate if it's already set,
otherwise calculate the mean bit rate from parsed frames. This way, the bit
rate will be set correctly both for CBR and VBR streams.

Signed-off-by: Alexander Kojevnikov <alexander@kojevnikov.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 29d8cd265a536063420afe78375b2176a9e1abc5)

Conflicts:

tests/ref/lavf-fate/mp3

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agodoc/APIchanges: List merge commit hashes and version numbers
Michael Niedermayer [Wed, 13 Feb 2013 02:32:23 +0000 (03:32 +0100)]
doc/APIchanges: List merge commit hashes and version numbers

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoapichanges: fix 2 wrong hashes
Michael Niedermayer [Thu, 14 Feb 2013 20:13:32 +0000 (21:13 +0100)]
apichanges: fix 2 wrong hashes

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2f3bc5122822687dc388f7352c92cf6db456cf7c)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoapichanges: Use , instead of / to seperate multiple hashes
Michael Niedermayer [Thu, 14 Feb 2013 19:34:10 +0000 (20:34 +0100)]
apichanges: Use , instead of / to seperate multiple hashes

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 33d6330652c088dadde163da569b1a2f6c7603c0)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoapichanges: fix date
Michael Niedermayer [Thu, 14 Feb 2013 19:32:24 +0000 (20:32 +0100)]
apichanges: fix date

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit ad6802f975a91bf6757fe3729ef8c6f10e6796b7)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agodoc/APIchanges: fix odd .01 versions
Michael Niedermayer [Thu, 14 Feb 2013 02:31:31 +0000 (03:31 +0100)]
doc/APIchanges: fix odd .01 versions

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 9f16cb9e50a5a196af9244dc7d33ed193227528a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoconfigure: Make warnings from -Wreturn-type fatal errors
Diego Biurrun [Mon, 14 Jan 2013 19:38:33 +0000 (20:38 +0100)]
configure: Make warnings from -Wreturn-type fatal errors

These warnings have no false positives and point to serious bugs.
(cherry picked from commit 99853cb8d4237b810b2fffb4a34f66fd0064ef72)

Conflicts:

configure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agomovenc: hotfix, dont store fiel for h264 / mpeg4-asp / dnxhd
Michael Niedermayer [Thu, 14 Feb 2013 16:11:34 +0000 (17:11 +0100)]
movenc: hotfix, dont store fiel for h264 / mpeg4-asp / dnxhd

Other software does not store it in this case, and the information
is provided by the codec stream

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 405cc0d9052079307b2b4188c396ae30c8e9108b)

Conflicts:

tests/ref/lavf/mov
tests/ref/seek/lavf_mov
tests/ref/vsynth/vsynth1-dnxhd-1080i
tests/ref/vsynth/vsynth1-mpeg4
tests/ref/vsynth/vsynth2-dnxhd-1080i
tests/ref/vsynth/vsynth2-mpeg4

6 years agohuffyuvdec: Skip len==0 cases
Michael Niedermayer [Tue, 29 Jan 2013 18:22:33 +0000 (19:22 +0100)]
huffyuvdec: Skip len==0 cases

Fixes vlc decoding for hypothetical files that would contain such cases.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 0dfc01c2bbf4b71bb56201bc4a393321e15d1b31)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5ff41ffeb4cb9ea6df49757dc859619dc3d3ab4f)

Conflicts:

libavcodec/huffyuv.c

6 years agohuffyuvdec: Check init_vlc() return codes.
Michael Niedermayer [Tue, 29 Jan 2013 17:29:41 +0000 (18:29 +0100)]
huffyuvdec: Check init_vlc() return codes.

Prevents out of array writes

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit f67a0d115254461649470452058fa3c28c0df294)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 95ab8d33e1a680f30a5a9605175112008ab81afc)

Conflicts:

libavcodec/huffyuv.c

6 years agortmp: fix buffer overflows in ff_amf_tag_contents()
Xi Wang [Wed, 23 Jan 2013 02:40:05 +0000 (21:40 -0500)]
rtmp: fix buffer overflows in ff_amf_tag_contents()

A negative `size' will bypass FFMIN().  In the subsequent memcpy() call,
`size' will be considered as a large positive value, leading to a buffer
overflow.

Change the type of `size' to unsigned int to avoid buffer overflow, and
simplify overflow checks accordingly.

Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 4e692374f7962ea358c329de38c380103f8991b6)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agortmp: fix multiple broken overflow checks
Xi Wang [Tue, 22 Jan 2013 22:49:29 +0000 (17:49 -0500)]
rtmp: fix multiple broken overflow checks

Sanity checks like `data + size >= data_end || data + size < data' are
broken, because `data + size < data' assumes pointer overflow, which is
undefined behavior in C.  Many compilers such as gcc/clang optimize such
checks away.

Use `size < 0 || size >= data_end - data' instead.

Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 902cfe2f74d777a7dc20ac68f2393b9f84b790c1)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agortpenc: fix overflow checking in avc_mp4_find_startcode()
Xi Wang [Wed, 23 Jan 2013 01:58:07 +0000 (20:58 -0500)]
rtpenc: fix overflow checking in avc_mp4_find_startcode()

The check `start + res < start' is broken since pointer overflow is
undefined behavior in C.  Many compilers such as gcc/clang optimize
away this check.

Use `res > end - start' instead.  Also change `res' to unsigned int
to avoid signed left-shift overflow.

Signed-off-by: Xi Wang <xi.wang@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2f014567cfd63e58156f60666f1a61ba147276ab)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agolavc/bink: Chech for malloc failure
James Almer [Wed, 6 Feb 2013 01:34:29 +0000 (22:34 -0300)]
lavc/bink: Chech for malloc failure

Based on commit 8ab2173ed141aa2c3336be7f9880340dfb8dcf5e

6 years agoDo not (re-)set libx264 parameter b_tff if interlaced encoding was not requested.
Carl Eugen Hoyos [Sat, 16 Mar 2013 19:13:44 +0000 (20:13 +0100)]
Do not (re-)set libx264 parameter b_tff if interlaced encoding was not requested.

Reconfiguring can break x264 lossless encoding.

Fixes ticket #2165.
(cherry picked from commit 75c7e4583f4fd727d236a12763a265502fe00988)

6 years agoaacsbr: Check for envelope scalefactors overflowing
Michael Niedermayer [Fri, 8 Mar 2013 13:00:22 +0000 (14:00 +0100)]
aacsbr: Check for envelope scalefactors overflowing

This prevents various values from becoming stuck at NAN and
output to become silent
If someone knows a cleaner solution, thats welcome!

Fixes Ticket2335

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 8978c743fb1d1f5a0d6dbdd83ff05817f8a41230)

6 years agoRequire at least three frames to autodetect loas.
Carl Eugen Hoyos [Sat, 2 Feb 2013 21:36:25 +0000 (22:36 +0100)]
Require at least three frames to autodetect loas.
(cherry picked from commit a60530e3ee1d9532c026a52b03661f88e163d647)

6 years agolavf/avio: check for : in filenames for protocols.
Nicolas George [Wed, 27 Feb 2013 18:19:15 +0000 (19:19 +0100)]
lavf/avio: check for : in filenames for protocols.

If the first "special" character in a filename is a comma,
it can introduce protocol options, but only if there is a
colon at the end. Otherwise, it is just a filename with a
comma.

Fix trac ticket #2303.
(cherry picked from commit d9fad53f4b447db1e436dcf3fc4a57e604616e6c)

6 years agoRevert "swfenc: use av_get_audio_frame_duration() instead of AVCodecContext.frame_size"
Carl Eugen Hoyos [Sun, 17 Feb 2013 19:55:37 +0000 (20:55 +0100)]
Revert "swfenc: use av_get_audio_frame_duration() instead of AVCodecContext.frame_size"

This reverts commit 620b88a302d522f71a6a95aff500cf7bd8520043.

Fixes ticket #2272.

6 years agoWrite the fiel atom to mov files independently of the used video coded.
Carl Eugen Hoyos [Thu, 14 Feb 2013 14:08:37 +0000 (15:08 +0100)]
Write the fiel atom to mov files independently of the used video coded.

The QuickTime specification does not contain any hint that the atom
must not be written in some cases and both the QuickTime and the
AVID decoders do not fail if the atom is present.

This change allows to signal (visually) interlaced streams with
a codec different from uncompressed video.

As a side-effect, this fixes ticket #2202
(cherry picked from commit 7d0e3b197c817b307d599a23704a44763ed0bbdd)

Conflicts:
libavformat/movenc.c
tests/ref/lavf/mov
tests/ref/seek/lavf_mov
tests/ref/vsynth/vsynth1-avui
tests/ref/vsynth/vsynth1-dnxhd-1080i
tests/ref/vsynth/vsynth1-mpeg4
tests/ref/vsynth/vsynth2-avui
tests/ref/vsynth/vsynth2-dnxhd-1080i
tests/ref/vsynth/vsynth2-mpeg4

6 years agosws: dont write out of array on bigendian
Carl Eugen Hoyos [Thu, 14 Feb 2013 13:40:26 +0000 (14:40 +0100)]
sws: dont write out of array on bigendian

Fixes Ticket2229

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 4e2c63685e031e28d2296cff76473b963ee62ba1)

6 years agoh264: Reset last_pocs in case of reference or frame number inconsistencies
Michael Niedermayer [Wed, 13 Feb 2013 21:36:07 +0000 (22:36 +0100)]
h264: Reset last_pocs in case of reference or frame number inconsistencies

This prevents faulty increasing of has_b_frames
Should fix Ticket 2062

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit c230af9bccc3cadb373f9007ba14fffb6c2acc75)

6 years agoh264_refs: Print default in case we are missing a reference.
Michael Niedermayer [Sun, 11 Nov 2012 01:47:38 +0000 (02:47 +0100)]
h264_refs: Print default in case we are missing a reference.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a39d36146a40cb52b3560fd02c73eccf72603b8f)

6 years agoffmpeg: dont allow -flags to override -pass
Michael Niedermayer [Wed, 6 Feb 2013 00:25:52 +0000 (01:25 +0100)]
ffmpeg: dont allow -flags to override -pass

Fixes Ticket2154

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit ccf9dd00da055e94117b56cead4af80ff331b00e)

Conflicts:
ffmpeg_opt.c

6 years agowtvdec: demux thumbnail picture to AVStream.attached_pic
Peter Ross [Sun, 6 Jan 2013 03:15:24 +0000 (14:15 +1100)]
wtvdec: demux thumbnail picture to AVStream.attached_pic

Fixes ticket #2133.

(cherry picked from commit 508836932fcbc3c109fcc4df7a2f2b0bf21bbece)

Conflicts:
libavformat/wtvdec.c

6 years agomatroskaenc: add codec_tag lists back.
Carl Eugen Hoyos [Thu, 24 Jan 2013 01:30:40 +0000 (02:30 +0100)]
matroskaenc: add codec_tag lists back.

This reverts 312645e :
"Do not set codec_tag property for matroska muxers."

Also adds dummy codec_tag lists with codecs
supported in mkv but not in wav / avi.

Fixes ticket #2169.
(cherry picked from commit df39c3ce385c02cbd8046298578ea7454c0a0f81)

Conflicts:
libavformat/matroskaenc.c

6 years agoFix detection of struct v4l2_frmsize_discrete.
Carl Eugen Hoyos [Thu, 17 Jan 2013 01:42:17 +0000 (02:42 +0100)]
Fix detection of struct v4l2_frmsize_discrete.

It was always detected successfully.

6 years agoff_get_audio_frame_size: try to fix wma in wav
Michael Niedermayer [Sun, 6 Jan 2013 18:15:16 +0000 (19:15 +0100)]
ff_get_audio_frame_size: try to fix wma in wav

Fixes Ticket1905, Ticket2114

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2713e43ac85245805db95048493dde121a20aee7)

6 years agotiffdec: Use the correct height field.
Piotr Bandurski [Sun, 6 Jan 2013 00:56:23 +0000 (01:56 +0100)]
tiffdec: Use the correct height field.

Fixes Ticket913

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 4784a135b2b0fe4d1b4c6256bd37265fc45aed3d)

6 years agolavf: Fix codec id forcing with probed codecs
Michael Niedermayer [Wed, 2 Jan 2013 01:38:11 +0000 (02:38 +0100)]
lavf: Fix codec id forcing with probed codecs

Fixes Ticket2088

(cherry picked from commit 341e40f1e1eeba1a2952c26363630596193e887b)

6 years agolavf: factor codec id forcing out
Michael Niedermayer [Fri, 7 Sep 2012 11:16:04 +0000 (13:16 +0200)]
lavf: factor codec id forcing out

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a7fbc7d7b7eabc74ceb1970a995c56043315e433)

Conflicts:
libavformat/utils.c

6 years agolavc/ass_split: check for NULL pointer in ff_ass_split_override_codes().
Clément Bœsch [Sun, 30 Dec 2012 05:53:48 +0000 (06:53 +0100)]
lavc/ass_split: check for NULL pointer in ff_ass_split_override_codes().

This is consistent with the other ff_ass_split_* functions.

It also fixes a crash when trying to split a dialog with text=NULL
(which seems to happen when the text of the dialog is empty); basically,
this commit fixes crashes when trying to encode an empty text subtitle
dialog (see subrip and mov_text encoders).

Fixes Ticket2048.
(cherry picked from commit c83002a4f8042ccfa0688a9a18e8fa0369c1fda8)

6 years agompeg1video: fix regression with slices != threads
Michael Niedermayer [Wed, 12 Dec 2012 18:52:46 +0000 (19:52 +0100)]
mpeg1video: fix regression with slices != threads

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a01679586cd9ac8470b81c0299fc7e13fd980d64)

6 years agompeg1video: support multi threaded slice encoding.
Michael Niedermayer [Wed, 12 Dec 2012 18:29:32 +0000 (19:29 +0100)]
mpeg1video: support multi threaded slice encoding.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 03df9720168335482f00898fc16b56ff4878d0e7)

Conflicts:
libavcodec/mpeg12enc.c

6 years agoavidec: try to support oddly muxed MMES stream
Michael Niedermayer [Thu, 22 Nov 2012 22:08:01 +0000 (23:08 +0100)]
avidec: try to support oddly muxed MMES stream

Fixes ticket1804

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit be89693ddc5a8cdeaf3edf48fb584d6adca54de0)

6 years agoriff: ignore ff_read_riff_info() failure.
Michael Niedermayer [Fri, 23 Nov 2012 22:35:16 +0000 (23:35 +0100)]
riff: ignore ff_read_riff_info() failure.

Some files simply contain invalid info tags.
Fixes unrelated bug posted into Ticket1821

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 09456d0df13404f004ab3a341d9ac21b7e5e6d6d)

6 years agoriff: retry reading metadata without padding if it fails with
Michael Niedermayer [Thu, 18 Oct 2012 02:58:20 +0000 (04:58 +0200)]
riff: retry reading metadata without padding if it fails with

Fixes Ticket1821

Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit d0c27e88d2bb495d61bd32f41769f767a0c2a802)

6 years agoh264: slice-mt: get last_pic_dropable from master context
Janne Grunau [Wed, 5 Dec 2012 18:56:36 +0000 (19:56 +0100)]
h264: slice-mt: get last_pic_dropable from master context

Fixes fate-h264-conformance-cvnlfi2_sony_h and smllwebdl.mkv from
https://github.com/OpenELEC/OpenELEC.tv/issues/1557 .
(cherry picked from commit 24c62ea7a5df44804be88150aa0c45e6796b5da9)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agomp3dec: Fix possibly exploitable crash
Michael Niedermayer [Thu, 27 Sep 2012 23:38:44 +0000 (01:38 +0200)]
mp3dec: Fix possibly exploitable crash

I was sadly unable to find a non fuzzed mp3 that uses the
feature that contained the bug (and i searched hard ...), thus
while this fixes the security issue. It may or may not fix
mixed blocks in 8khz mp3s, i cant say due to lack of samples to test.

Security issue exists since: b37d945dd4213cb8e92146571b0374cd45d52286

Reported-by: Dale Curtis <dalecurtis@google.com>
(Probably) Found-by: inferno@chromium.org
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 94041febc53a6da10e34c2bfff9ff1d580fdce60)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agolavf: compute probe buffer size more reliably.
Nicolas George [Tue, 4 Dec 2012 18:49:51 +0000 (19:49 +0100)]
lavf: compute probe buffer size more reliably.

The previous code computes the offset by reversing the growth
of the allocated buffer size: it is complex and did lead to
inconsistencies when the size limit is reached.

Fix trac ticket #1991.
(cherry picked from commit 03847eb8259291b4ff1bd840bd779d0699d71f96)

Conflicts:
libavformat/utils.c
(cherry picked from commit e74cd2f4706f71da5e9205003c1d8263b54ed3fb)

6 years agoChangelog for 0.11.2 n0.11.2
Michael Niedermayer [Wed, 19 Sep 2012 01:11:27 +0000 (03:11 +0200)]
Changelog for 0.11.2

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoarm/intmath: disable av_clip_uintp2_arm with config_small
Michael Niedermayer [Tue, 12 Jun 2012 21:04:16 +0000 (23:04 +0200)]
arm/intmath: disable av_clip_uintp2_arm with config_small

The code otherwise breaks compilation (gcc 4.5 tested but probably any compiler)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2942431a0f94ecb77744a772c164ab71711ffe19)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoUpdate for 0.11.2
Michael Niedermayer [Fri, 14 Sep 2012 22:27:17 +0000 (00:27 +0200)]
Update for 0.11.2

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoaasc: fix out of array write
Paul B Mahol [Wed, 8 Aug 2012 14:10:06 +0000 (14:10 +0000)]
aasc: fix out of array write

Closes #1619.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
(cherry picked from commit 8a57ca5c6a1c0ad28afa7ea6f824981e6761cce1)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agobmv_videodec: fix out of array read
Michael Niedermayer [Tue, 14 Aug 2012 16:58:49 +0000 (18:58 +0200)]
bmv_videodec: fix out of array read

Fixes Ticket1373

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 70f0ffa1ed456fd0b560d0dd1d0d93f1ba3a6d93)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agofaxcompr: fix out of array read
Michael Niedermayer [Fri, 7 Sep 2012 10:35:41 +0000 (12:35 +0200)]
faxcompr: fix out of array read

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5891e454a667e42ef71a06bfd9661540ea3f3ebd)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoescape124: fix integer overflow leading to excessive memory allocation
Michael Niedermayer [Thu, 16 Aug 2012 20:28:29 +0000 (22:28 +0200)]
escape124: fix integer overflow leading to excessive memory allocation

Fixes Ticket1629

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 3d7817048cb387de87600f2152075f78b37b60a6)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agosp5xdec: fix off by 1 error causing a crash
Michael Niedermayer [Thu, 16 Aug 2012 01:15:14 +0000 (03:15 +0200)]
sp5xdec: fix off by 1 error causing a crash

Fixes Ticket1633

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit f0896a6bd94e5b45447c7d640c8e8aa95d860d7a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agompegaudio_parser: reset state to prevent it to be random
Michael Niedermayer [Fri, 14 Sep 2012 03:55:11 +0000 (05:55 +0200)]
mpegaudio_parser: reset state to prevent it to be random

Fixes Ticket1718

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 93b240f4a59348c07d3d7e4862227f6949c51e14)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agopthread: Avoid crashes/odd behavior caused by spurious wakeups
Ben Jackson [Fri, 14 Sep 2012 04:26:43 +0000 (21:26 -0700)]
pthread: Avoid crashes/odd behavior caused by spurious wakeups

pthread_wait_cond can wake up for no reason (Wikipedia: Spurious_wakeup).
The FF_THREAD_SLICE thread mechanism could spontaneously execute jobs or
allow the caller of avctx->execute to return before all jobs were complete.
This adds tests to both cases to ensure the wakeup is real.

Signed-off-by: Ben Jackson <ben@ben.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e3329474a366de066b25e86f35f5abf9c5a4b7b2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agolavfi/aresample: set buffer properties after copy.
Nicolas George [Wed, 12 Sep 2012 17:34:21 +0000 (19:34 +0200)]
lavfi/aresample: set buffer properties after copy.

The aresample filter changes the format, layout and/or sample rate,
it can not copy them blindly from its input.

Fix trac ticket 1671 because af_volume uses the properties from the
buffer and not from the link.

6 years agolavfi/audio: fix an invalid boundary check.
Nicolas George [Wed, 12 Sep 2012 17:33:42 +0000 (19:33 +0200)]
lavfi/audio: fix an invalid boundary check.

6 years agoFix muxing mjpeg in swf.
Carl Eugen Hoyos [Wed, 12 Sep 2012 11:08:27 +0000 (13:08 +0200)]
Fix muxing mjpeg in swf.
(cherry picked from commit 7680d99b4302e476076cc1b8f2567f47c2aaef4d)

6 years agobuild: Fix some paths in uninstall-libs
jamal [Fri, 3 Aug 2012 20:13:27 +0000 (17:13 -0300)]
build: Fix some paths in uninstall-libs

Folder and file names weren't being separated with a slash.
This resulted in .dll.a, .lib and .def files not being removed on uninstall.

Signed-off-by: Alexander Strasser <eclipse7@gmx.net>
(cherry picked from commit 49440853d0c1e740daee0e2df1e65d5e67b1ad6b)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agodoc/Makefile: Add missing $(HOSTEXESUF) to print_options
jamal [Thu, 12 Jul 2012 01:45:00 +0000 (22:45 -0300)]
doc/Makefile: Add missing $(HOSTEXESUF) to print_options
(cherry picked from commit d48f014ff1db985fa3f74eddfb30bf513f99ff7a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agodxva2: include dxva.h if found
Ronald S. Bultje [Sun, 24 Jun 2012 10:17:13 +0000 (11:17 +0100)]
dxva2: include dxva.h if found

Apparently, some build environments require dxva.h even for dxva2,
while others lack this header entirely.  Including it conditionally
allows building in both cases.

Signed-off-by: Martin Storsjö <martin@martin.st>
(cherry picked from commit fa84506177f0246b30d4ea6a99ee5d419f3e4550)

Conflicts:

configure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoconfigure: fix sctp check.
Michael Niedermayer [Wed, 8 Aug 2012 14:01:01 +0000 (16:01 +0200)]
configure: fix sctp check.

This fixes build failures on debian/kfreebsd

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit bed63a5e98b1ba1f3bca6c81ea819666c2d81fde)

Conflicts:

configure

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
6 years agoClarify that -passlogfile has a different syntax when used with -vcodec libx264.
Carl Eugen Hoyos [Fri, 31 Aug 2012 12:16:36 +0000 (14:16 +0200)]
Clarify that -passlogfile has a different syntax when used with -vcodec libx264.

7 years agooggdec: Initialize stream index to -1 in ogg_packet.
Reimar Döffinger [Sun, 5 Aug 2012 07:45:04 +0000 (09:45 +0200)]
oggdec: Initialize stream index to -1 in ogg_packet.

The previous method of having to initialize it outside lead
to incorrect code: even if it was initialized, it usually was
only initialized once, thus a packet that could not be matched
to any stream would just be processed with the return values
from the previous call.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
(cherry picked from commit 69aeba1396d5a13e79cbc3cc9f49fd6896addb82)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agooggdec: simplify start time calculation code.
Reimar Döffinger [Sun, 5 Aug 2012 07:41:20 +0000 (09:41 +0200)]
oggdec: simplify start time calculation code.

Also slightly more correct behaviour in case streams_left for
some reason is 0 from the start.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
(cherry picked from commit a4163b2d6583396845e06b1b976c3a981eb8cb1c)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agooggdec: check stream index before using it in ogg_get_length()
Michael Niedermayer [Sun, 5 Aug 2012 02:41:34 +0000 (04:41 +0200)]
oggdec: check stream index before using it in ogg_get_length()

Fixes crash based on a uninitialized array index read.
If the read does not crash then out of array writes based
on the same index might have been triggered afterwards.

Found-by: inferno@chromium.org
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 9e1c55cfdec1e1e46fa39b92ea5c425ba9499c68)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agowmaenc: dont mess with the bitrate.
Michael Niedermayer [Mon, 2 Jul 2012 10:47:08 +0000 (12:47 +0200)]
wmaenc: dont mess with the bitrate.

The bitrate is not writeable by an encoder.
Fixes generation of invalid wma

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoUpdate for 0.11.1 n0.11.1
Michael Niedermayer [Thu, 7 Jun 2012 20:53:09 +0000 (22:53 +0200)]
Update for 0.11.1
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoprobetest: allow specifying parameters on the command line
Michael Niedermayer [Thu, 31 May 2012 13:53:58 +0000 (15:53 +0200)]
probetest: allow specifying parameters on the command line

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 6cfaccabc4edc3321c9a47e349236815b9d649e2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agompegvideo: fix out of heap array accesses
Michael Niedermayer [Wed, 6 Jun 2012 17:26:21 +0000 (19:26 +0200)]
mpegvideo: fix out of heap array accesses

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 317ca0d3f735fad354c404e8bbac3e1ce9f09b12)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agosearch_for_quantizers_faac: fix curband
Michael Niedermayer [Wed, 6 Jun 2012 16:35:05 +0000 (18:35 +0200)]
search_for_quantizers_faac: fix curband

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 33775c3507f4e0977d8ef1d8c5cbd167d0429319)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoffmpeg: avoid a confusing and easy to break if().
Reimar Döffinger [Wed, 6 Jun 2012 10:39:07 +0000 (12:39 +0200)]
ffmpeg: avoid a confusing and easy to break if().

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 93147daf59b096f3d6ad6d9e8d8c11c293e425d2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoffmpeg: use isatty() before messing with the terminal state
Michael Niedermayer [Tue, 5 Jun 2012 17:58:03 +0000 (19:58 +0200)]
ffmpeg: use isatty() before messing with the terminal state

This fixes terminal messup in case of crashes (like in make fate)

Reviewed-by: François Revol <revol@free.fr>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit c8a11014b673ebc6946db6fcd20009d330c57c48)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoswr-test: support "--help"
Michael Niedermayer [Tue, 5 Jun 2012 15:12:50 +0000 (17:12 +0200)]
swr-test: support "--help"

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 787c395a30ecc87bd6dadf2ec1ccab8648653880)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agobuildsys: fix rules for swresample-test
Michael Niedermayer [Tue, 5 Jun 2012 15:06:19 +0000 (17:06 +0200)]
buildsys: fix rules for swresample-test

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 63b1c08073adefb93c9fe8e3a6fd9c1b99772b7e)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoMake H264 reorder buffer size message less verbose.
Carl Eugen Hoyos [Tue, 5 Jun 2012 10:52:07 +0000 (12:52 +0200)]
Make H264 reorder buffer size message less verbose.
(cherry picked from commit a3bc7f916dcc69cfa439b424352d5951b4eaf9b8)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoAdd missing CRLFs to avisynth error messages.
Carl Eugen Hoyos [Tue, 5 Jun 2012 09:13:30 +0000 (11:13 +0200)]
Add missing CRLFs to avisynth error messages.
(cherry picked from commit 1faf0d6a7a70cb0bcfbbff0421fb00bb6da658f9)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoFix MP2 muxer Makefile dependencies.
Carl Eugen Hoyos [Tue, 5 Jun 2012 07:54:03 +0000 (09:54 +0200)]
Fix MP2 muxer Makefile dependencies.

Found, analysed and tested by trac user Jamal.

Fixes ticket #1411
(cherry picked from commit 757d5b9bfda45e45d9ab28ad4d5a9205119fe549)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agompc8: fix maximum bands handling
Kostya Shishkov [Mon, 4 Jun 2012 06:01:34 +0000 (08:01 +0200)]
mpc8: fix maximum bands handling

In Musepack SV8 codec property tell the maximum nonzero band, but every
frame codes maximum band as a limit (i.e. strictly less than given value).
Synthesis also expects maximum nonzero band, so there's a need to convert
frame maximum band limit value.
(cherry picked from commit b56825c40ee1329b33aed34ff8a639fa18d263a0)

Conflicts:

libavcodec/mpc8.c

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoaacdec: Turn PS off when switching to stereo and turn it to implicit when switching...
Alex Converse [Tue, 22 May 2012 21:43:28 +0000 (14:43 -0700)]
aacdec: Turn PS off when switching to stereo and turn it to implicit when switching to mono.
(cherry picked from commit 79c8e29a7e404dbcf670df599fad6894f98ccab2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoFix compilation condition for some ProRes dsp encoder functions.
Carl Eugen Hoyos [Mon, 4 Jun 2012 10:18:56 +0000 (12:18 +0200)]
Fix compilation condition for some ProRes dsp encoder functions.

Found, analysed and tested by trac user Jamal.

Fixes part of Ticket #1404.
(cherry picked from commit 568a5924180b0ce43e2706bf2491b70c455eb36a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoFix compilation condition for some ProRes dsp decoder functions.
Carl Eugen Hoyos [Mon, 4 Jun 2012 10:15:41 +0000 (12:15 +0200)]
Fix compilation condition for some ProRes dsp decoder functions.

Found, analysed and tested by trac user Jamal.

Fixes part of Ticket #1404.
(cherry picked from commit 84986b4e61994c64ef2ea6161c473f82a2672cbc)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoFix ProRes decoder Makefile dependencies.
Carl Eugen Hoyos [Mon, 4 Jun 2012 10:07:30 +0000 (12:07 +0200)]
Fix ProRes decoder Makefile dependencies.

Found, analysed and tested by trac user Jamal.

Fixes part of Ticket #1404.
(cherry picked from commit a4b885d55ee061fa8df089f356ddbabf0282da5f)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoFix G.723.1 encoder Makefile dependencies.
Carl Eugen Hoyos [Mon, 4 Jun 2012 10:06:48 +0000 (12:06 +0200)]
Fix G.723.1 encoder Makefile dependencies.
(cherry picked from commit c02ef0788178d859f829c9703325e247b60e1895)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoffv1dec: print more information for -debug 1
Michael Niedermayer [Sun, 3 Jun 2012 23:00:26 +0000 (01:00 +0200)]
ffv1dec: print more information for -debug 1

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 38c9ebd2a97a1298e4c5cc9d01d88d69c55be695)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoffv1: fix log level of FF_DEBUG_PICT_INFO
Michael Niedermayer [Sun, 3 Jun 2012 22:55:02 +0000 (00:55 +0200)]
ffv1: fix log level of FF_DEBUG_PICT_INFO

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 730d079bf756c40f4a3c4624388db11d1be3475f)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agompc8: fix channel checks
Michael Niedermayer [Sun, 3 Jun 2012 15:40:30 +0000 (17:40 +0200)]
mpc8: fix channel checks

fix heap array overflow

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 44c10168cff41c200825448b77cb8feff0d316c9)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoav_get_audio_frame_duration: fix FPE
Michael Niedermayer [Sun, 3 Jun 2012 15:12:26 +0000 (17:12 +0200)]
av_get_audio_frame_duration: fix FPE

Fixes ticket1392

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a5ad3c2382ac27cf712aaba6a222ec12f5eb88da)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agomace: check channel count, fixes FPE
Michael Niedermayer [Sun, 3 Jun 2012 12:53:43 +0000 (14:53 +0200)]
mace: check channel count, fixes FPE

Fixes ticket1391

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 6df1cfa7e4d488051d7b5033c0c69df970db9f82)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoh263: disable loop filter with lowres
Michael Niedermayer [Sun, 3 Jun 2012 12:41:21 +0000 (14:41 +0200)]
h263: disable loop filter with lowres

Fixes ticket1212

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit cc229d4e83889d1298f1a0863b55feec6c5c339a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agompc7: fix handling of last frame
Michael Niedermayer [Sat, 2 Jun 2012 21:43:31 +0000 (23:43 +0200)]
mpc7: fix handling of last frame

Fixes heap buffer overflow
Fixes ticket1393

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e95233789c08f55c0b2d0657bada609629a59294)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agooggdec: fix regression that caused reading the whole file during open
Michael Niedermayer [Sat, 2 Jun 2012 20:50:40 +0000 (22:50 +0200)]
oggdec: fix regression that caused reading the whole file during open

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e0eaf1004910e451cbb8dbcb5c54ac63721adb61)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agopng_parser: dont falsely mark frames as keyframes
Michael Niedermayer [Sat, 2 Jun 2012 19:12:20 +0000 (21:12 +0200)]
png_parser: dont falsely mark frames as keyframes

Fixes Ticket1381

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 82570d2f09e76d262f4eb57b591b08c4aa64729a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agolavf: use input keyframe flag when muxer does not provide keyframe flags.
Michael Niedermayer [Sat, 2 Jun 2012 19:11:43 +0000 (21:11 +0200)]
lavf: use input keyframe flag when muxer does not provide keyframe flags.

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5665674b55a45df757ed4fcd076a5cdf9ab484b6)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agobink: fix out of reference frame read
Michael Niedermayer [Sat, 2 Jun 2012 17:56:10 +0000 (19:56 +0200)]
bink: fix out of reference frame read

Fixes Ticket1374

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit b3675f890abee0bc446495711223a5c790234672)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoh264: log debug output for slightly truncated streams
Michael Niedermayer [Sat, 2 Jun 2012 13:37:20 +0000 (15:37 +0200)]
h264: log debug output for slightly truncated streams

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit fb4e434cfb5bf5510bf9ade40a9b63e3a579247e)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agoh264: try to better handle h264 streams that are slightly truncated
Michael Niedermayer [Sat, 2 Jun 2012 11:58:28 +0000 (13:58 +0200)]
h264: try to better handle h264 streams that are slightly truncated

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit cd0f9f00a2471891b692729d8e62c8979396a2ee)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agobmv: fix apparent sign error in the frame_off check
Michael Niedermayer [Sat, 2 Jun 2012 02:06:16 +0000 (04:06 +0200)]
bmv: fix apparent sign error in the frame_off check

Fixes part of Ticket1373

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit debbcfae6010f027a0334d70d0dbb7ddd912ad5a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
7 years agobmv: fix integer overflows in vlc decoder.
Michael Niedermayer [Sat, 2 Jun 2012 02:04:29 +0000 (04:04 +0200)]
bmv: fix integer overflows in vlc decoder.

Fixes part of Ticket1373

Found-by: Piotr Bandurski <ami_stuff@o2.pl>
Based-on-patch-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 679c578cb8e82df6fdee977e3137a26a680ad346)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>