Commit d10361b6 authored by Martin Storsjö's avatar Martin Storsjö

avio: Free URLContext private data allocated via AVOptions

Signed-off-by: 's avatarMartin Storsjö <martin@martin.st>
parent 6c643e07
......@@ -335,8 +335,11 @@ int ffurl_close(URLContext *h)
#if CONFIG_NETWORK
ff_network_close();
#endif
if (h->prot->priv_data_size)
if (h->prot->priv_data_size) {
if (h->prot->priv_data_class)
av_opt_free(h->priv_data);
av_free(h->priv_data);
}
av_free(h);
return ret;
}
......
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