aboutsummaryrefslogtreecommitdiff
path: root/databases/mysql50-server
diff options
context:
space:
mode:
authorAlex Dupre <ale@FreeBSD.org>2008-01-21 07:15:53 +0000
committerAlex Dupre <ale@FreeBSD.org>2008-01-21 07:15:53 +0000
commitf7b84ee5afb344edcec12f85d85104fbde9d6578 (patch)
tree10ea0574f14cafd5cabc3dcb7a43d979b206636a /databases/mysql50-server
parent9b052163d052ea73a63946e8b9d0b5a288a789e6 (diff)
downloadports-f7b84ee5afb344edcec12f85d85104fbde9d6578.tar.gz
ports-f7b84ee5afb344edcec12f85d85104fbde9d6578.zip
Notes
Diffstat (limited to 'databases/mysql50-server')
-rw-r--r--databases/mysql50-server/files/patch-vio_viossl.c57
1 files changed, 57 insertions, 0 deletions
diff --git a/databases/mysql50-server/files/patch-vio_viossl.c b/databases/mysql50-server/files/patch-vio_viossl.c
new file mode 100644
index 000000000000..7614326aeaae
--- /dev/null
+++ b/databases/mysql50-server/files/patch-vio_viossl.c
@@ -0,0 +1,57 @@
+--- vio/viossl.c.orig 2007-11-15 15:07:13.000000000 +0100
++++ vio/viossl.c 2008-01-21 08:02:45.000000000 +0100
+@@ -172,20 +172,14 @@
+ vio_delete(vio);
+ }
+
+-int sslaccept(struct st_VioSSLFd *ptr, Vio *vio, long timeout)
+-{
+- DBUG_ENTER("sslaccept");
+- DBUG_RETURN(sslconnect(ptr, vio, timeout));
+-}
+-
+-
+-int sslconnect(struct st_VioSSLFd *ptr, Vio *vio, long timeout)
++static
++int sslprocess(struct st_VioSSLFd *ptr, Vio *vio, long timeout, my_bool accept)
+ {
+ SSL *ssl;
+ my_bool unused;
+ my_bool was_blocking;
+
+- DBUG_ENTER("sslconnect");
++ DBUG_ENTER("sslprocess");
+ DBUG_PRINT("enter", ("ptr: 0x%lx, sd: %d ctx: 0x%lx",
+ (long) ptr, vio->sd, (long) ptr->ssl_context));
+
+@@ -201,6 +195,12 @@
+ }
+ DBUG_PRINT("info", ("ssl: 0x%lx timeout: %ld", (long) ssl, timeout));
+ SSL_clear(ssl);
++
++ if (accept)
++ SSL_set_accept_state(ssl);
++ else
++ SSL_set_connect_state(ssl);
++
+ SSL_SESSION_set_timeout(SSL_get_session(ssl), timeout);
+ SSL_set_fd(ssl, vio->sd);
+
+@@ -258,6 +258,17 @@
+ DBUG_RETURN(0);
+ }
+
++int sslaccept(struct st_VioSSLFd *ptr, Vio *vio, long timeout)
++{
++ DBUG_ENTER("sslaccept");
++ DBUG_RETURN(sslprocess(ptr, vio, timeout, TRUE));
++}
++
++int sslconnect(struct st_VioSSLFd *ptr, Vio *vio, long timeout)
++{
++ DBUG_ENTER("sslconnect");
++ DBUG_RETURN(sslprocess(ptr, vio, timeout, FALSE));
++}
+
+ int vio_ssl_blocking(Vio *vio __attribute__((unused)),
+ my_bool set_blocking_mode,