diff options
Diffstat (limited to 'src/core/network-openssl.c')
-rw-r--r-- | src/core/network-openssl.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/src/core/network-openssl.c b/src/core/network-openssl.c index 1eb85341..aab9176d 100644 --- a/src/core/network-openssl.c +++ b/src/core/network-openssl.c @@ -20,6 +20,7 @@ #include "module.h" #include "network.h" +#include "net-sendbuffer.h" #include "misc.h" #include "servers.h" #include "signals.h" @@ -701,6 +702,21 @@ GIOChannel *net_connect_ip_ssl(IPADDR *ip, int port, IPADDR *my_ip, SERVER_REC * return ssl_handle; } +GIOChannel *net_start_ssl(SERVER_REC *server) +{ + GIOChannel *handle, *ssl_handle; + + g_return_val_if_fail(server != NULL, NULL); + + handle = net_sendbuffer_handle(server->handle); + if (handle == NULL) + return NULL; + + ssl_handle = irssi_ssl_get_iochannel(handle, server->connrec->port, server); + return ssl_handle; +} + + int irssi_ssl_handshake(GIOChannel *handle) { GIOSSLChannel *chan = (GIOSSLChannel *)handle; |