avformat/vapoursynth: properly initialize err variable in read_header_vs()

The variable "err" is not initialized, and set only when something went wrong.
When everything is OK, nobody sets it, so using it result in UB.

Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
nu774 2019-01-04 02:17:02 +09:00 committed by Michael Niedermayer
parent 4fd6df6934
commit e0686318dd

View File

@ -177,7 +177,7 @@ static av_cold int read_header_vs(AVFormatContext *s)
char dummy;
const VSVideoInfo *info;
struct VSState *vss_state;
int err;
int err = 0;
vss_state = av_mallocz(sizeof(*vss_state));
if (!vss_state) {