[vlc-commits] sftp: do not force TCP, SOCKS
Rémi Denis-Courmont
git at videolan.org
Sun Nov 18 16:57:05 CET 2018
vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Sat Nov 17 19:23:02 2018 +0200| [76f3805d6f2f9b31bf88faf554160f4b0b885e2d] | committer: Rémi Denis-Courmont
sftp: do not force TCP, SOCKS
libssh2 can accept any type of stream sockets - though that's largely
theoretical in this case - so there are no particular reasons to force
TCP here.
Regarding SOCKS, OpenSSH can be used to provide a server, but does not
generally act as a client. It seemed rather odd for VLC SFTP to use
SOCKS when normal command line SFTP does not.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=76f3805d6f2f9b31bf88faf554160f4b0b885e2d
---
modules/access/sftp.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/modules/access/sftp.c b/modules/access/sftp.c
index 8baa320eb7..da68998ff4 100644
--- a/modules/access/sftp.c
+++ b/modules/access/sftp.c
@@ -195,7 +195,8 @@ static int SSHSessionInit( stream_t *p_access, const char *psz_host, int i_port
/* Connect to the server using a regular socket */
assert( p_sys->i_socket == -1 );
- p_sys->i_socket = net_ConnectTCP( p_access, psz_host, i_port );
+ p_sys->i_socket = net_Connect( p_access, psz_host, i_port, SOCK_STREAM,
+ 0 );
if( p_sys->i_socket < 0 )
goto error;
More information about the vlc-commits
mailing list