35950 Commits

Author SHA1 Message Date
Michael Niedermayer
0064fcb486 mlp_parser: Fix infinite loop with 0 bytes_left.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e146ad95d79b1a6e6b9e566366b832825c79679f)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:43:02 +01:00
Reimar Döffinger
a4269652ab Avoid av_memcpy_backptr hang without extra branch.
This only happens for a "back" value of 0 which is invalid anyway,
but lcldec does not properly validate input.
Also extend the documentation to specify valid values.

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:42:12 +01:00
Michael Niedermayer
3ccbd6b06d ljpegdec: fix point transform injection.
Fix Ticket842

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:41:59 +01:00
Michael Niedermayer
fa97a8030f flvdec: Check index for being valid
Fixes seeking in Enigma_Principles_of_Lust.flv

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:41:40 +01:00
Michael Niedermayer
53c430415a 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>
(cherry picked from commit b9e0e9537a3ec4af1630e9f1b8d0ce68885cac16)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:41:16 +01:00
Michael Niedermayer
f246d46ee6 indeo5: Fix null pointer dereferences of ref_mb
Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit f41a6c8f3aeb51332bb359038cb504d3fb562a52)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:40:58 +01:00
Michael Niedermayer
94773637ba h264_mp4toannexb_filter: pass error code through.
Bug-Found-by and Suggested bugfix: Tanami, Ohad
Reviewed-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 7ae251b4d8a18bc63734e58f1baafac634c67e01)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:40:49 +01:00
Michael Niedermayer
e1152971a6 issdemux: Check packet_size for validity
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit bf5cc805190b5811b786a454f01cccf9a7e366b9)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:40:24 +01:00
Michael Niedermayer
7cd9732b33 qpeg: Check for overread in qpeg_decode_intra.
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit e7c1e38ba632f7315e332dd350b38f782f428884)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:40:17 +01:00
Michael Niedermayer
acdc505b2a indeo5: fix division by 0 in ff_ivi_init_tiles()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 92e2b59dec8c0124a209ce24f23450df9607d9d8)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:39:40 +01:00
Michael Niedermayer
f09bbd38b0 indeo5: Fix crash due to partially initialized gop vars.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit d46bc4133c104188dd6719365605e42bd1b5e2ff)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:38:58 +01:00
Michael Niedermayer
690fda3ae4 indeo5: fix null pointer crash with ref_mb
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 4b35ee0b7c0c4cbac3541a25a5e8c00b657c8f95)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:38:35 +01:00
Michael Niedermayer
0280cf9aa7 vcr1dec: Check that there is sufficient input data.
Fixes crash.

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:38:22 +01:00
Michael Niedermayer
a47c277205 v410dec: Check for sufficient input data.
Fixes crash

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:38:16 +01:00
Kostya Shishkov
b0355d3253 Indeo 4 decoder
Signed-off-by: Kostya Shishkov <kostya.shishkov@gmail.com>
(cherry picked from commit adfe0c942e71545f003f9c4d148fbf5d220681bc)

Conflicts:

	Changelog
	libavcodec/version.h

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:38:07 +01:00
Carl Eugen Hoyos
e9ce8a4480 Fix a crash when reading gray pam files.
Fixes ticket #837.
(cherry picked from commit 190a0998c353879c8f79f47678752dbb8fa62bb2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:36:22 +01:00
Stefano Sabatini
e9378b42b1 lavfi: add missing check in avfilter_filter_samples()
Avoid out-of-buffer data access when nb_channels is 8.
(cherry picked from commit ae21776207e8a2bbe268e7c9e203f7599dd87ddb)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:35:42 +01:00
Michael Niedermayer
6caca26533 shorten: validate values in fmt chunk search
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5e9a56a0350c518cd4b38845aff49d41a9c952ae)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:33:21 +01:00
Michael Niedermayer
446d11f5ed shorten: Fix invalid free()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 18bcfc912e48bf77a5202a0e24a3b884b9b2ff2c)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:33:15 +01:00
Michael Niedermayer
a80205ff82 segafilm: fail earlier in case theres not enough bytestream left for a
audio packet.
This prevents a potentially large memory allocation.

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:32:39 +01:00
Michael Niedermayer
0231a68ecd avio: Fix ffio_limit() when due to seeking past the end less than 0 bytes remain.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 27d323577c19af218f8a5ac33364f213b623a023)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:32:28 +01:00
Michael Niedermayer
7c67d9c6fb golomb: Fix infinite loop in svq3_get_ue_golomb()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 964506bb979e8c972833c7421a39f3275d3cd3c0)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:32:19 +01:00
Michael Niedermayer
49db360005 ws_snd1: Fix wrong samples count and crash.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 5257743aee0c3982f0079e6553aabc6aa39401d2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:32:14 +01:00
Michael Niedermayer
42476635ba asfdec: fix endless loop on EOF
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 0d4404ed65e6ebfdf5e3c09f9e3a2a41dde18e4a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:32:04 +01:00
Michael Niedermayer
462ecdb9bb sierravmd: limit packetsize to the amount that could be read.
Fixes huge allocations.

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:57 +01:00
Michael Niedermayer
6210d62c5f vmdav: check that theres enough space for a chunk remaining.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 2278ecc434d390bccd32a083a12ab964a6b7b0ce)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:46 +01:00
Michael Niedermayer
a1666ae8f0 rmdec: Avoid allocating huge packets
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 66f71f3b5e2e7b6e5049bd9831c371e16aff8a53)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:35 +01:00
Michael Niedermayer
f69045793d mpeg4videodec: Fix division by zero in mpeg4_decode_sprite_trajectory()
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit fc5c49ab3247533e0a5cb203cf7122143389eb5c)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:24 +01:00
Michael Niedermayer
adf0c1c70c rpl: Fix near infinite loop in index reading due to missing eof check.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 43abef9fde0cf87153cc9031cad61f75b02cfa01)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:16 +01:00
Michael Niedermayer
3073564a97 j2kdec: Fix crash in get_qcx
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 282bb02839b1ce73963c8e3ee46804f1ade8b12a)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:31:06 +01:00
Michael Niedermayer
5e3389b742 j2kdec: Check curtileno for validity
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 3eedf9f716733b3b4c5205726d2c1ca52b3d3d78)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:30:59 +01:00
Michael Niedermayer
f41e935225 j2kdec: Check for interger overflow in tile array allocation
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 3132999fdb57d8d3ba5e08a4dc1b3661e885c04d)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:30:47 +01:00
Michael Niedermayer
897088d604 j2kdec: fix division by zero, check tile dimensions for validity
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 628c9dcca3fb3f46f960f0df8236591653c6e512)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:30:32 +01:00
Michael Niedermayer
7dbdf02abc lzo: fix memcpy_backptr() with 0 offset
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 58c41799ab6b52df86b6afe23304f34b62741326)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:30:25 +01:00
Jean First
f21771260b libopenjpeg: support decoding with bits per pixel greater than 8
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
Approved-by: Alex Zhukov
(cherry picked from commit 0d4a77472ad8a4d194e93379a992f66c33fbf144)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:30:08 +01:00
Michael Niedermayer
a9de82ac17 avio: fix handling of , in urls
Fixes Ticket805

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:29:21 +01:00
Carl Eugen Hoyos
340fee05f0 Release buffers after encoding svq1.
Fixes ticket #820.
(cherry picked from commit 8e88145d0b43a4572c1c13431c4f7ba644547c80)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:27:59 +01:00
Carl Eugen Hoyos
a5546736bd Fix a possible endless loop when decoding aac.
Fixes ticket #789.
(cherry picked from commit e5de9289232c5b14572fa13e2435f9adb0b0f1ec)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:27:49 +01:00
Alexander Strange
3aa89662ce h264: Fix a possible overread in decode_nal_units()
Signed-off-by: Anton Khirnov <anton@khirnov.net>
(cherry picked from commit bc6a3bd4a544608211f006e2d2868cbed4e1fde6)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:27:36 +01:00
Michael Niedermayer
ed0dc01a47 h264: Decode short VUI without error
Fixes 47j9R7PXBep.mov

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:27:02 +01:00
Sergey Radionov
4a4e4b8139 w32thread: call ResetEvent() in pthread_cond_broadcast().
Also add "volatile" to broadcast flag (since it is used from
multiple threads).

Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
(cherry picked from commit 01eb9805f37835e20501134ae26e379140fe3239)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:26:47 +01:00
Michael Niedermayer
33636442e2 udp: support non blocking reads with fifo
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 9f50dafe9025555f11e66e3b09cf3db2cd53cfb2)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:26:26 +01:00
Michael Niedermayer
3710f0b9ed udp: Replace double select() by select+mutex+cond.
When no data was available both the buffer thread as well as
the main thread would block in select(), when data becomes
available both should move forward and as data is read in the
buffer thread the main thread would block in select() later
the read data was put in the fifo but the main thread still
would be blocked in select() until either the timeout or
another packet would come in.

This is solved in this commit by using a mutex and a condition
variable

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:26:20 +01:00
Michael Niedermayer
12d0e44bdb udp: return circular buffer error if such error happened.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit 3dcbafc777513621e423c2f23b1725559230383d)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:26:06 +01:00
Michael Niedermayer
857d64a58c fifo: Make writes atomic.
Prior to this a X bytes write could be seen as less than X bytes being
available if the check was done at an unfortunate moment.

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

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:25:53 +01:00
Gaurav Narula
a644934b80 kvmc: fix invalid reads
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
(cherry picked from commit ad3161ec1d70291efcf40121d703ef73c0b08e5b)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:25:47 +01:00
Paul B Mahol
89cf156ace adpcm: fix IMA SMJPEG decoding
Signed-off-by: Janne Grunau <janne-libav@jannau.net>
(cherry picked from commit 01a01bf8bdafab1c81c3039850aba042b247626f)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:25:03 +01:00
Janne Grunau
4f94de84e8 pthreads: reset active_thread_type when slice thread_init returrns early
(cherry picked from commit f77f640b3035d357a6c6ffcea243c7ea0d8ebc67)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 22:24:57 +01:00
Justin Ruggles
9665ccda10 ra144enc: zero the reflection coeffs if the filter is unstable
fixes use of uninitialized values if the filter is still unstable after using
the previous frame lpc coefficients.
(cherry picked from commit 9a3f10695a011861dcf5a649e3e72580b1a4eed4)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 21:51:53 +01:00
Paul B Mahol
8dce2dd9cc lavf: Add SMJPEG demuxer.
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
(cherry picked from commit a4209ad6313b8b40fed2bfc7e3865cf54d4c1022)

Conflicts:

	Changelog
	doc/general.texi
	libavformat/version.h

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
2012-01-03 21:51:53 +01:00