lavf: Reset the entry count and allocation size variables on av_reallocp failures

When av_reallocp fails, the associated variables that keep track of
the number of elements in the array (and in some cases, the
separate number of allocated elements) need to be reset.

Not all of these might technically be needed, but it's better to
reset them if in doubt, to make sure variables don't end up
conflicting.

Signed-off-by: Martin Storsjö <martin@martin.st>
lxf: Support version 1 files

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
lxf: Support 16-channel files

Reported, analyzed and tested by Gabriel Gerard.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
pcm: support 24-bit/32-bit little-endian planar

Used by LXF.

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
lxf: remove deplanarization hack

Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
lxf: check the nb_streams instead of relying on padding

Remove the now unneeded stream pointer while at it.

Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
CC: libav-stable@libav.org
Merge commit 'd872fb0f7ff2ff0ba87f5ccf6a1a55ca2be472c9'

* commit 'd872fb0f7ff2ff0ba87f5ccf6a1a55ca2be472c9':
  lavf: Reset the entry count and allocation size variables on av_reallocp failures

Conflicts:
	libavformat/avienc.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit '839df90c718dcab9b9e91ca3c7e73479b3e8103c'

* commit '839df90c718dcab9b9e91ca3c7e73479b3e8103c':
  lxf: Support 16-channel files
  lxf: Support version 1 files

Conflicts:
	libavformat/lxfdec.c

See: e701b0cf7553202085840d3bfd1aff432b4de513
See: 1a06d6dd866318b49596c0bf5ed03917f952d3bd
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit '7e52080cb18332cb1da9fe133498750b6b4b0fb3'

* commit '7e52080cb18332cb1da9fe133498750b6b4b0fb3':
  pcm: support 24-bit/32-bit little-endian planar

Conflicts:
	doc/general.texi
	libavcodec/Makefile
	libavcodec/allcodecs.c
	libavcodec/avcodec.h
	libavcodec/pcm.c
	libavcodec/version.h
	libavformat/nut.c

See: 467dfd5dfae7cc435a2b2e7cf012a0de2fea5848
Merged-by: Michael Niedermayer <michaelni@gmx.at>
Merge commit 'a529fa2f4dd3292ba7d9cd3e6ba76425b1ba7aef'

* commit 'a529fa2f4dd3292ba7d9cd3e6ba76425b1ba7aef':
  lxf: remove deplanarization hack

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

* qatar/master:
  lxf: check the nb_streams instead of relying on padding

Conflicts:
	libavformat/lxfdec.c

Merged-by: Michael Niedermayer <michaelni@gmx.at>
avfilter/af_ladspa: refactor code setting input control ports values

Signed-off-by: Paul B Mahol <onemda@gmail.com>
avfilter/af_ladspa: allow changing controls dynamically

Signed-off-by: Paul B Mahol <onemda@gmail.com>
avfilter/af_ladspa: set output channel layout for passthrough case

For cases when plugin does not return any samples we just return
input samples. Previously channel layout for outlink was not set.
Set it explicitly instead.

Signed-off-by: Paul B Mahol <onemda@gmail.com>
avformat/tls: fix {} error for the GNUTLS case

Found-by:" Geek.Song" <ffmpeg@gmail.com>
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avfilter/vidstabtransform: update optzoom range values for recent vid.stab update.

Signed-off-by: Georg Martius <martius@mis.mpg.de>
avformat/mxfdec: check sample size more completely

Fixes division by zero
Fixes Ticket2992

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avcodec/mlpdec: Fail if the input is too small

This fixes a infinite loop
Fixes Ticket2986

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
avfilter: add av_cold to init()

Signed-off-by: Paul B Mahol <onemda@gmail.com>
fate: add phase test

Signed-off-by: Paul B Mahol <onemda@gmail.com>