Skip to content
Snippets Groups Projects
Commit e8769b37 authored by Xi Wang's avatar Xi Wang Committed by Martin Storsjö
Browse files

segment: fix NULL pointer dereference in seg_write_header()


Since the pointer `oc' is NULL, oc->oformat->name will cause a null
pointer dereference.  This patch changes it to seg->oformat->name.

Signed-off-by: default avatarXi Wang <xi.wang@gmail.com>
Signed-off-by: default avatarMartin Storsjö <martin@martin.st>
parent 26301caa
No related branches found
No related tags found
No related merge requests found
......@@ -210,7 +210,7 @@ static int seg_write_header(AVFormatContext *s)
}
if (seg->oformat->flags & AVFMT_NOFILE) {
av_log(s, AV_LOG_ERROR, "format %s not supported.\n",
oc->oformat->name);
seg->oformat->name);
ret = AVERROR(EINVAL);
goto fail;
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment