Commit 94a752b7 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

s/OpenTCP/ConnectTCP/ for consistency

and other cosmetic fixes
parent 499c0ee2
......@@ -5,7 +5,7 @@
* $Id$
*
* Authors: Laurent Aimar <fenrir@via.ecp.fr> - original code
* Rmi Denis-Courmont <rem # videolan.org> - EPSV support
* Rémi Denis-Courmont <rem # videolan.org> - EPSV support
*
* This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
......@@ -106,7 +106,7 @@ static int Connect( access_t *p_access, access_sys_t *p_sys )
/* *** Open a TCP connection with server *** */
msg_Dbg( p_access, "waiting for connection..." );
p_sys->fd_cmd = fd = net_OpenTCP( p_access, p_sys->url.psz_host,
p_sys->fd_cmd = fd = net_ConnectTCP( p_access, p_sys->url.psz_host,
p_sys->url.i_port );
if( fd < 0 )
{
......@@ -617,7 +617,7 @@ static int ftp_StartStream( access_t *p_access, off_t i_start )
}
msg_Dbg( p_access, "waiting for data connection..." );
p_sys->fd_data = net_OpenTCP( p_access, psz_ip, i_port );
p_sys->fd_data = net_ConnectTCP( p_access, psz_ip, i_port );
if( p_sys->fd_data < 0 )
{
msg_Err( p_access, "failed to connect with server" );
......
......@@ -763,7 +763,7 @@ static int Connect( access_t *p_access, int64_t i_tell )
/* Open connection */
p_sys->fd = net_OpenTCP( p_access, srv.psz_host, srv.i_port );
p_sys->fd = net_ConnectTCP( p_access, srv.psz_host, srv.i_port );
if( p_sys->fd < 0 )
{
msg_Err( p_access, "cannot connect to %s:%d", srv.psz_host, srv.i_port );
......
......@@ -386,7 +386,7 @@ static int Describe( access_t *p_access, char **ppsz_location )
p_sys->p_packet = NULL;
E_( GenerateGuid )( &p_sys->guid );
if( ( p_sys->fd = net_OpenTCP( p_access, p_sys->url.psz_host,
if( ( p_sys->fd = net_ConnectTCP( p_access, p_sys->url.psz_host,
p_sys->url.i_port ) ) < 0 )
{
msg_Err( p_access, "cannot connect to %s:%d", p_sys->url.psz_host, p_sys->url.i_port );
......@@ -574,7 +574,7 @@ static int Start( access_t *p_access, off_t i_pos )
msg_Dbg( p_access, "starting stream" );
if( ( p_sys->fd = net_OpenTCP( p_access, p_sys->url.psz_host,
if( ( p_sys->fd = net_ConnectTCP( p_access, p_sys->url.psz_host,
p_sys->url.i_port ) ) < 0 )
{
/* should not occur */
......
......@@ -458,7 +458,7 @@ static int MMSOpen( access_t *p_access, vlc_url_t *p_url, int i_proto )
/* *** Open a TCP connection with server *** */
msg_Dbg( p_access, "waiting for connection..." );
p_sys->i_handle_tcp = net_OpenTCP( p_access, p_url->psz_host, p_url->i_port );
p_sys->i_handle_tcp = net_ConnectTCP( p_access, p_url->psz_host, p_url->i_port );
if( p_sys->i_handle_tcp < 0 )
{
msg_Err( p_access, "failed to open a connection (tcp)" );
......
......@@ -84,7 +84,7 @@ static int RtspConnect( void *p_userdata, char *psz_server, int i_port )
access_sys_t *p_sys = p_access->p_sys;
/* Open connection */
p_sys->fd = net_OpenTCP( p_access, psz_server, i_port );
p_sys->fd = net_ConnectTCP( p_access, psz_server, i_port );
if( p_sys->fd < 0 )
{
msg_Err( p_access, "cannot connect to %s:%d", psz_server, i_port );
......
......@@ -110,7 +110,7 @@ static int Open( vlc_object_t *p_this )
p_access->info.i_seekpoint = 0;
p_access->p_sys = p_sys = malloc( sizeof( access_sys_t ) );
p_sys->fd = net_OpenTCP( p_access, psz_dup, atoi( psz_parser ) );
p_sys->fd = net_ConnectTCP( p_access, psz_dup, atoi( psz_parser ) );
free( psz_dup );
if( p_sys->fd < 0 )
......
......@@ -444,7 +444,7 @@ static int OpenUDP( vlc_object_t * p_this )
/* set the time-to-live */
int i_ttl = p_socket->i_ttl;
unsigned char ttl;
/* set the multicast interface */
char * psz_mif_addr = config_GetPsz( p_this, "miface-addr" );
if( psz_mif_addr )
......
......@@ -300,11 +300,10 @@ static int OpenUDP( vlc_object_t * p_this )
msg_Err( p_this, "failed to join IP multicast group (%s)",
strerror(errno) );
}
}
}
else
{
struct ipv6_mreq imr;
int res;
......
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