summaryrefslogtreecommitdiff
path: root/lib/libssl
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@cvs.openbsd.org>2018-02-26 16:02:15 +0000
committerIngo Schwarze <schwarze@cvs.openbsd.org>2018-02-26 16:02:15 +0000
commit4f8bc7412b863b80995a38a9941cffe0484c4b05 (patch)
tree24469a66987ee347a30ea28955f369ba510bfa84 /lib/libssl
parenta306955a6dae9e775eebed97b0286f3da03e52b9 (diff)
In ssl.h rev. 1.142 2018/02/22 17:25:18, jsing@ provided
SSL_SESSION_up_ref(3). Merge the documentation from OpenSSL, tweaked by me.
Diffstat (limited to 'lib/libssl')
-rw-r--r--lib/libssl/man/SSL_SESSION_free.335
1 files changed, 23 insertions, 12 deletions
diff --git a/lib/libssl/man/SSL_SESSION_free.3 b/lib/libssl/man/SSL_SESSION_free.3
index 1a37af2775b..13c03fda438 100644
--- a/lib/libssl/man/SSL_SESSION_free.3
+++ b/lib/libssl/man/SSL_SESSION_free.3
@@ -1,8 +1,10 @@
-.\" $OpenBSD: SSL_SESSION_free.3,v 1.2 2016/12/06 18:53:55 schwarze Exp $
-.\" OpenSSL b97fdb57 Nov 11 09:33:09 2016 +0100
+.\" $OpenBSD: SSL_SESSION_free.3,v 1.3 2018/02/26 16:02:14 schwarze Exp $
+.\" full merge up to: OpenSSL b31db505 Mar 24 16:01:50 2017 +0000
.\"
-.\" This file was written by Lutz Jaenicke <jaenicke@openssl.org>.
-.\" Copyright (c) 2000, 2001, 2009 The OpenSSL Project. All rights reserved.
+.\" This file was written by Lutz Jaenicke <jaenicke@openssl.org>
+.\" and Matt Caswell <matt@openssl.org>.
+.\" Copyright (c) 2000, 2001, 2009, 2017 The OpenSSL Project.
+.\" All rights reserved.
.\"
.\" Redistribution and use in source and binary forms, with or without
.\" modification, are permitted provided that the following conditions
@@ -48,25 +50,31 @@
.\" ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED
.\" OF THE POSSIBILITY OF SUCH DAMAGE.
.\"
-.Dd $Mdocdate: December 6 2016 $
+.Dd $Mdocdate: February 26 2018 $
.Dt SSL_SESSION_FREE 3
.Os
.Sh NAME
+.Nm SSL_SESSION_up_ref ,
.Nm SSL_SESSION_free
-.Nd free an allocated SSL_SESSION structure
+.Nd SSL_SESSION reference counting
.Sh SYNOPSIS
.In openssl/ssl.h
+.Ft int
+.Fn SSL_SESSION_up_ref "SSL_SESSION *session"
.Ft void
.Fn SSL_SESSION_free "SSL_SESSION *session"
.Sh DESCRIPTION
-.Fn SSL_SESSION_free
-decrements the reference count of
+.Fn SSL_SESSION_up_ref
+increments the reference count of the given
.Fa session
-and removes the
-.Vt SSL_SESSION
-structure pointed to by
+by 1.
+.Pp
+.Fn SSL_SESSION_free
+decrements the reference count of the given
.Fa session
-and frees up the allocated memory, if the reference count has reached 0.
+by 1.
+If the reference count reaches 0, it frees the memory used by the
+.Fa session .
If
.Fa session
is a
@@ -120,6 +128,9 @@ It must not be called on other
.Vt SSL_SESSION
objects, as this would cause incorrect reference counts and therefore program
failures.
+.Sh RETURN VALUES
+.Fn SSL_SESSION_up_ref
+returns 1 on success or 0 on error.
.Sh SEE ALSO
.Xr d2i_SSL_SESSION 3 ,
.Xr SSL_CTX_flush_sessions 3 ,