mirror of
https://github.com/mpv-player/mpv
synced 2025-03-01 03:40:43 +00:00
missing url_free when using proxy and connect fails
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@17778 b3059339-0415-0410-9bf9-f77b7e298cf2
This commit is contained in:
parent
cd94e7a740
commit
5b3801e774
@ -431,6 +431,7 @@ http_send_request( URL_t *url, off_t pos ) {
|
||||
if( url->port==0 ) url->port = 8080; // Default port for the proxy server
|
||||
fd = connect2Server( url->hostname, url->port,1 );
|
||||
url_free( server_url );
|
||||
server_url = NULL;
|
||||
} else {
|
||||
if( server_url->port==0 ) server_url->port = 80; // Default port for the web server
|
||||
fd = connect2Server( server_url->hostname, server_url->port,1 );
|
||||
@ -451,6 +452,8 @@ http_send_request( URL_t *url, off_t pos ) {
|
||||
return fd;
|
||||
err_out:
|
||||
http_free(http_hdr);
|
||||
if (proxy && server_url)
|
||||
url_free(server_url);
|
||||
return -1;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user