examples/c/decode/file/main.c : Add extra error handling.
authorErik de Castro Lopo <erikd@mega-nerd.com>
Thu, 20 Nov 2014 10:19:36 +0000 (21:19 +1100)
committerErik de Castro Lopo <erikd@mega-nerd.com>
Thu, 20 Nov 2014 10:46:57 +0000 (21:46 +1100)
commit93846ee22383fae4a57dc467022524d9d828694a
tree189405dba2a4068eb583281d082660a4c1328402
parent5b3033a2b355068c11fe637e14ac742d273f076e
examples/c/decode/file/main.c : Add extra error handling.

Michele Spagnuolo provided a file that initially had frames with two
channels but then had a frame with a single channel. This example
program only supports exactly two channels and previously had
insufficient validation.

Closes: https://sourceforge.net/p/flac/bugs/418/
Reported-by: Michele Spagnuolo,
             Google Security Team <mikispag@google.com>
examples/c/decode/file/main.c