diff options
Diffstat (limited to 'src/lib/libssl/doc/SSL_free.3')
| -rw-r--r-- | src/lib/libssl/doc/SSL_free.3 | 59 |
1 files changed, 59 insertions, 0 deletions
diff --git a/src/lib/libssl/doc/SSL_free.3 b/src/lib/libssl/doc/SSL_free.3 new file mode 100644 index 0000000000..453cd7d424 --- /dev/null +++ b/src/lib/libssl/doc/SSL_free.3 | |||
| @@ -0,0 +1,59 @@ | |||
| 1 | .Dd $Mdocdate: October 12 2014 $ | ||
| 2 | .Dt SSL_FREE 3 | ||
| 3 | .Os | ||
| 4 | .Sh NAME | ||
| 5 | .Nm SSL_free | ||
| 6 | .Nd free an allocated SSL structure | ||
| 7 | .Sh SYNOPSIS | ||
| 8 | .In openssl/ssl.h | ||
| 9 | .Ft void | ||
| 10 | .Fn SSL_free "SSL *ssl" | ||
| 11 | .Sh DESCRIPTION | ||
| 12 | .Fn SSL_free | ||
| 13 | decrements the reference count of | ||
| 14 | .Fa ssl , | ||
| 15 | and removes the | ||
| 16 | .Vt SSL | ||
| 17 | structure pointed to by | ||
| 18 | .Fa ssl | ||
| 19 | and frees up the allocated memory if the reference count has reached 0. | ||
| 20 | .Sh NOTES | ||
| 21 | .Fn SSL_free | ||
| 22 | also calls the | ||
| 23 | .Xr free 3 Ns | ||
| 24 | ing procedures for indirectly affected items, if applicable: the buffering | ||
| 25 | .Vt BIO , | ||
| 26 | the read and write | ||
| 27 | .Vt BIOs , | ||
| 28 | cipher lists specially created for this | ||
| 29 | .Fa ssl , | ||
| 30 | the | ||
| 31 | .Sy SSL_SESSION . | ||
| 32 | Do not explicitly free these indirectly freed up items before or after calling | ||
| 33 | .Fn SSL_free , | ||
| 34 | as trying to free things twice may lead to program failure. | ||
| 35 | .Pp | ||
| 36 | The | ||
| 37 | .Fa ssl | ||
| 38 | session has reference counts from two users: the | ||
| 39 | .Vt SSL | ||
| 40 | object, for which the reference count is removed by | ||
| 41 | .Fn SSL_free | ||
| 42 | and the internal session cache. | ||
| 43 | If the session is considered bad, because | ||
| 44 | .Xr SSL_shutdown 3 | ||
| 45 | was not called for the connection and | ||
| 46 | .Xr SSL_set_shutdown 3 | ||
| 47 | was not used to set the | ||
| 48 | .Vt SSL_SENT_SHUTDOWN | ||
| 49 | state, the session will also be removed from the session cache as required by | ||
| 50 | RFC2246. | ||
| 51 | .Sh RETURN VALUES | ||
| 52 | .Fn SSL_free | ||
| 53 | does not provide diagnostic information. | ||
| 54 | .Sh SEE ALSO | ||
| 55 | .Xr ssl 3 , | ||
| 56 | .Xr SSL_clear 3 , | ||
| 57 | .Xr SSL_new 3 , | ||
| 58 | .Xr SSL_set_shutdown 3 , | ||
| 59 | .Xr SSL_shutdown 3 | ||
