avio: Free URLContext private data allocated via AVOptions
Signed-off-by: Martin Storsjö <martin@martin.st>
This commit is contained in:
@@ -335,8 +335,11 @@ int ffurl_close(URLContext *h)
|
|||||||
#if CONFIG_NETWORK
|
#if CONFIG_NETWORK
|
||||||
ff_network_close();
|
ff_network_close();
|
||||||
#endif
|
#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->priv_data);
|
||||||
|
}
|
||||||
av_free(h);
|
av_free(h);
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user