From: Antonio Quartulli <anto...@mandelbit.com> When creating a socket to connect to a remote (this happens in client mode) always use the protocol specified for the remote.
The listening protocol in this case is just ignored as it does not make any sense. Change-Id: I6d2ec69ac7a9ef5900d8f1d8541d6a19c9cb7df9 Signed-off-by: Antonio Quartulli <anto...@mandelbit.com> Acked-by: Arne Schwabe <arne-open...@rfc2549.org> --- This change was reviewed on Gerrit and approved by at least one developer. I request to merge it to master. Gerrit URL: https://gerrit.openvpn.net/c/openvpn/+/911 This mail reflects revision 1 of this Change. Acked-by according to Gerrit (reflected above): Arne Schwabe <arne-open...@rfc2549.org> diff --git a/src/openvpn/socket.c b/src/openvpn/socket.c index 6b32e30..ad97830 100644 --- a/src/openvpn/socket.c +++ b/src/openvpn/socket.c @@ -1886,6 +1886,11 @@ const char *remote_host = o->ce.remote; const char *remote_port = o->ce.remote_port; + if (remote_host) + { + proto = o->ce.proto; + } + if (c->mode == CM_CHILD_TCP || c->mode == CM_CHILD_UDP) { struct link_socket *tmp_sock = NULL; _______________________________________________ Openvpn-devel mailing list Openvpn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/openvpn-devel