diff options
author | unknown <gluh@eagle.intranet.mysql.r18.ru> | 2005-11-21 16:09:26 +0400 |
---|---|---|
committer | unknown <gluh@eagle.intranet.mysql.r18.ru> | 2005-11-21 16:09:26 +0400 |
commit | 31ea9f945d2acfa8e0dec18df8ae7094d7ca62b0 (patch) | |
tree | b333cc8af1bc5e2584d134438936662fc0e10da2 /vio | |
parent | 1dfaaba874c5f02222e149466743abb0c268c5d3 (diff) | |
download | mariadb-git-31ea9f945d2acfa8e0dec18df8ae7094d7ca62b0.tar.gz |
Fix for bug#14780 memory leak for mysql 4.1.14 with openssl enabled
Diffstat (limited to 'vio')
-rw-r--r-- | vio/vio.c | 2 | ||||
-rw-r--r-- | vio/vio_priv.h | 1 | ||||
-rw-r--r-- | vio/viossl.c | 19 |
3 files changed, 1 insertions, 21 deletions
diff --git a/vio/vio.c b/vio/vio.c index 427c52e29d3..6174acd7024 100644 --- a/vio/vio.c +++ b/vio/vio.c @@ -83,7 +83,7 @@ void vio_reset(Vio* vio, enum enum_vio_type type, #ifdef HAVE_OPENSSL if (type == VIO_TYPE_SSL) { - vio->viodelete =vio_ssl_delete; + vio->viodelete =vio_delete; vio->vioerrno =vio_ssl_errno; vio->read =vio_ssl_read; vio->write =vio_ssl_write; diff --git a/vio/vio_priv.h b/vio/vio_priv.h index c1c78cc6efa..eb495025ddd 100644 --- a/vio/vio_priv.h +++ b/vio/vio_priv.h @@ -28,7 +28,6 @@ void vio_ignore_timeout(Vio *vio, uint which, uint timeout); #ifdef HAVE_OPENSSL #include "my_net.h" /* needed because of struct in_addr */ -void vio_ssl_delete(Vio* vio); int vio_ssl_read(Vio *vio,gptr buf, int size); int vio_ssl_write(Vio *vio,const gptr buf,int size); void vio_ssl_timeout(Vio *vio, uint which, uint timeout); diff --git a/vio/viossl.c b/vio/viossl.c index a3a2e7190bd..62145fe5006 100644 --- a/vio/viossl.c +++ b/vio/viossl.c @@ -69,25 +69,6 @@ report_errors() DBUG_VOID_RETURN; } -/* - Delete a vio object - - SYNPOSIS - vio_ssl_delete() - vio Vio object. May be 0. -*/ - - -void vio_ssl_delete(Vio * vio) -{ - if (vio) - { - if (vio->type != VIO_CLOSED) - vio_close(vio); - my_free((gptr) vio,MYF(0)); - } -} - int vio_ssl_errno(Vio *vio __attribute__((unused))) { |