Commit c84ba07d authored by Michael Niedermayer's avatar Michael Niedermayer

avformat/mux: Check that deinit is set before calling it

Fixes null pointer dereference
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent dbe1dd59
......@@ -424,7 +424,8 @@ FF_ENABLE_DEPRECATION_WARNINGS
}
if (s->oformat->init && (ret = s->oformat->init(s)) < 0) {
s->oformat->deinit(s);
if (s->oformat->deinit)
s->oformat->deinit(s);
goto fail;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment