mem: Handle av_reallocp(..., 0) properly

Previously this did a double free (and returned an error).

Reported-by: Justin Ruggles
Signed-off-by: Martin Storsjö <martin@martin.st>
h264dec: K&R formatting cosmetics

Signed-off-by: Diego Biurrun <diego@biurrun.de>
h264dec: Add .avc file name extension

Signed-off-by: Diego Biurrun <diego@biurrun.de>
Apply clut changes only to one table.

The specification does not allow multiple bits to be set,
but some encoders do it anyway.
Applying it only to the first seems to give better results.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
dvbsubdec: Check for invalid clut selector.

Fail decoding if strict compliance is requested.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
fate: add adelay test

Signed-off-by: Paul B Mahol <onemda@gmail.com>
Merge commit '67e285ceca1cb602a5ab87010b30d904527924fe'

* commit '67e285ceca1cb602a5ab87010b30d904527924fe':
  mem: Handle av_reallocp(..., 0) properly

Merged-by: Michael Niedermayer <michaelni@gmx.at>
mpeg4dec: Ensure data is not clobbered too early.

Avoid overwriting the bitstream buffer data before we
have ended processing the frame.
This is necessary to fix hwaccels which might try to use
the buffer during the end_frame call.
I am not sure but it is possible this could even trigger
a use-after-free if the av_fast_malloc allocated a new buffer.
This would require that decode_slice did not wind the bitstream
forward all the way to the end, which does not currently happen in
normal streams.

Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
Allow encoding YUVJ422P and YUVJ444P with libx264.

Reviewed-by: Reimar
Merge commit '01f111bdb21b4ea6d2ff3ea919d70ae9ca451cf9'

* commit '01f111bdb21b4ea6d2ff3ea919d70ae9ca451cf9':
  h264dec: K&R formatting cosmetics

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge remote-tracking branch 'qatar/master'

* qatar/master:
  h264dec: Add .avc file name extension

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Remove '-vf' from pullup documentation example.
Merge remote-tracking branch 'cehoyos/master'

* cehoyos/master:
  Allow encoding YUVJ422P and YUVJ444P with libx264.

Merged-by: Michael Niedermayer <michaelni@gmx.at>
matroska: Add the CueDuration element

Use it only on subtitle CuePoints.
With proper demuxer/splitter support this should improve the display
of subtitles right after seeking to a given point in the stream.

Signed-off-by: James Almer <jamrial@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tools: Fix apparent merge failure
avfilter/vf_tinterlace: add yuv411p, yuv440p, yuva422p and yuva444p

Signed-off-by: Paul B Mahol <onemda@gmail.com>
lavfi/pad,crop,scale: remove options description from filter description

Signed-off-by: Paul B Mahol <onemda@gmail.com>
avcodec/fraps: use BT.709 colorspace for YUV Fraps versions

Based both on comparison to the reference decoder, and comments from
the fraps developers upon inquiry how to handle the yuv fraps variants.
avutil/cpu: remove duplicate include

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avfilter: remove duplicate includes

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