25 lines
997 B
Diff
25 lines
997 B
Diff
|
Index: src/core/servers.c
|
||
|
===================================================================
|
||
|
--- src/core/servers.c (revision 5169)
|
||
|
+++ src/core/servers.c (working copy)
|
||
|
@@ -209,6 +209,7 @@
|
||
|
char *errmsg2;
|
||
|
char ipaddr[MAX_IP_LEN];
|
||
|
int port;
|
||
|
+ char *hostname;
|
||
|
|
||
|
g_return_if_fail(ip != NULL || unix_socket != NULL);
|
||
|
|
||
|
@@ -223,8 +224,10 @@
|
||
|
server->connrec->own_ip4);
|
||
|
port = server->connrec->proxy != NULL ?
|
||
|
server->connrec->proxy_port : server->connrec->port;
|
||
|
+ hostname = server->connrec->proxy != NULL ?
|
||
|
+ server->connrec->proxy : server->connrec->address;
|
||
|
handle = server->connrec->use_ssl ?
|
||
|
- net_connect_ip_ssl(ip, port, server->connrec->address, own_ip, server->connrec->ssl_cert, server->connrec->ssl_pkey,
|
||
|
+ net_connect_ip_ssl(ip, port, hostname, own_ip, server->connrec->ssl_cert, server->connrec->ssl_pkey,
|
||
|
server->connrec->ssl_cafile, server->connrec->ssl_capath, server->connrec->ssl_verify) :
|
||
|
net_connect_ip(ip, port, own_ip);
|
||
|
} else {
|