aboutsummaryrefslogtreecommitdiff
path: root/ssl/ssl_lib.c
diff options
context:
space:
mode:
authorRichard Levitte <levitte@openssl.org>2001-07-15 20:11:57 +0000
committerRichard Levitte <levitte@openssl.org>2001-07-15 20:11:57 +0000
commit24cbf3efc68cc3b6f41c39960e72f69b0ed9fe60 (patch)
tree72031dbff61bad440f9656a036ae1a6bcb5482af /ssl/ssl_lib.c
parent534a1ed0cba281f7a51291777964f5dd683abede (diff)
downloadopenssl-24cbf3efc68cc3b6f41c39960e72f69b0ed9fe60.zip
openssl-24cbf3efc68cc3b6f41c39960e72f69b0ed9fe60.tar.gz
openssl-24cbf3efc68cc3b6f41c39960e72f69b0ed9fe60.tar.bz2
SSL_get_[rw]fd were documented but not implemented.
Diffstat (limited to 'ssl/ssl_lib.c')
-rw-r--r--ssl/ssl_lib.c17
1 files changed, 17 insertions, 0 deletions
diff --git a/ssl/ssl_lib.c b/ssl/ssl_lib.c
index ad1af7c..463ed16 100644
--- a/ssl/ssl_lib.c
+++ b/ssl/ssl_lib.c
@@ -445,6 +445,11 @@ BIO *SSL_get_wbio(SSL *s)
int SSL_get_fd(SSL *s)
{
+ return(SSL_get_rfc(s));
+ }
+
+int SSL_get_rfd(SSL *s)
+ {
int ret= -1;
BIO *b,*r;
@@ -455,6 +460,18 @@ int SSL_get_fd(SSL *s)
return(ret);
}
+int SSL_get_wfd(SSL *s)
+ {
+ int ret= -1;
+ BIO *b,*r;
+
+ b=SSL_get_wbio(s);
+ r=BIO_find_type(b,BIO_TYPE_DESCRIPTOR);
+ if (r != NULL)
+ BIO_get_fd(r,&ret);
+ return(ret);
+ }
+
#ifndef OPENSSL_NO_SOCK
int SSL_set_fd(SSL *s,int fd)
{