ffmdec: reject zero-sized chunks
authorAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Wed, 2 Dec 2015 21:47:12 +0000 (22:47 +0100)
committerAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Thu, 17 Dec 2015 20:19:19 +0000 (21:19 +0100)
commite56d32203289e579959f4097ad67d8305a952d7b
tree9c7349ba3a784f399d79068d2b38d18b1add6cf6
parent3ffc22443579c761caec43a650db198cf165a04c
ffmdec: reject zero-sized chunks

If size is zero, avio_get_str fails, leaving the buffer uninitialized.
This causes invalid reads in av_set_options_string.

Reviewed-by: Michael Niedermayer <michael@niedermayer.cc>
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
(cherry picked from commit a611375db532c3d5363d97b10fadd0211811a4fd)
Signed-off-by: Andreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
libavformat/ffmdec.c