diff options
author | Timo Sirainen <cras@irssi.org> | 2003-11-16 18:00:23 +0000 |
---|---|---|
committer | cras <cras@dbcabf3a-b0e7-0310-adc4-f8d773084564> | 2003-11-16 18:00:23 +0000 |
commit | 0ece10f26ad1c3114fa587a5b823564ea7e7c335 (patch) | |
tree | 34d0528b38f0ffb810b5f333975fe1ea002d1e80 /src | |
parent | d6fe016c78e675a3d9844dea02eac6b38f6caf59 (diff) | |
download | irssi-0ece10f26ad1c3114fa587a5b823564ea7e7c335.zip |
compile fix for glib2
git-svn-id: http://svn.irssi.org/repos/irssi/trunk@3148 dbcabf3a-b0e7-0310-adc4-f8d773084564
Diffstat (limited to 'src')
-rw-r--r-- | src/core/network-openssl.c | 47 |
1 files changed, 24 insertions, 23 deletions
diff --git a/src/core/network-openssl.c b/src/core/network-openssl.c index 1ae3a589..e8100b7c 100644 --- a/src/core/network-openssl.c +++ b/src/core/network-openssl.c @@ -54,29 +54,6 @@ static void irssi_ssl_free(GIOChannel *handle) g_free(chan); } -#if GLIB_MAJOR_VERSION < 2 - -#ifdef G_CAN_INLINE -G_INLINE_FUNC -#else -static -#endif -GIOError ssl_errno(gint e) -{ - switch(e) - { - case EINVAL: - return G_IO_ERROR_INVAL; - case EINTR: - case EAGAIN: - return G_IO_ERROR_AGAIN; - default: - return G_IO_ERROR_INVAL; - } - /*UNREACH*/ - return G_IO_ERROR_INVAL; -} - static gboolean irssi_ssl_verify(SSL *ssl, SSL_CTX *ctx, X509 *cert) { if (SSL_get_verify_result(ssl) != X509_V_OK) { @@ -117,6 +94,30 @@ static gboolean irssi_ssl_verify(SSL *ssl, SSL_CTX *ctx, X509 *cert) return TRUE; } + +#if GLIB_MAJOR_VERSION < 2 + +#ifdef G_CAN_INLINE +G_INLINE_FUNC +#else +static +#endif +GIOError ssl_errno(gint e) +{ + switch(e) + { + case EINVAL: + return G_IO_ERROR_INVAL; + case EINTR: + case EAGAIN: + return G_IO_ERROR_AGAIN; + default: + return G_IO_ERROR_INVAL; + } + /*UNREACH*/ + return G_IO_ERROR_INVAL; +} + static GIOError irssi_ssl_cert_step(GIOSSLChannel *chan) { X509 *cert; |