提交 d3f84dfc 编写于 作者: M Martin Storsjö

RTSP: Clean up rtsp_hd on failure

Since rtsp_hd isn't assigned to rt->rtsp_hd until after the setup phase,
the initialized URLContext could be leaked on failures.

Originally committed as revision 23643 to svn://svn.ffmpeg.org/ffmpeg/trunk
上级 e8ccf245
......@@ -1594,12 +1594,14 @@ redirect:
/* complete the connection */
if (url_read(rtsp_hd, NULL, 0)) {
url_close(rtsp_hd);
err = AVERROR(EIO);
goto fail;
}
/* POST requests */
if (url_open(&rtsp_hd_out, httpname, URL_WRONLY) < 0 ) {
url_close(rtsp_hd);
err = AVERROR(EIO);
goto fail;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册