mirror of
https://github.com/mirror/wget.git
synced 2025-03-01 21:30:20 +08:00
Add ssl_cleanup to free memory
* src/ssl.h: Add declaration for ssl_cleanup. * src/openssl.c: Add ssl_cleanup stub. * src/gnutls.c: Implement ssl_cleanup.
This commit is contained in:
parent
7146b9dc77
commit
b209ca91fb
@ -226,6 +226,15 @@ cert to be of the same type.\n"));
|
|||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
ssl_cleanup (void)
|
||||||
|
{
|
||||||
|
if (credentials)
|
||||||
|
gnutls_certificate_free_credentials(credentials);
|
||||||
|
|
||||||
|
gnutls_global_deinit();
|
||||||
|
}
|
||||||
|
|
||||||
struct wgnutls_transport_context
|
struct wgnutls_transport_context
|
||||||
{
|
{
|
||||||
gnutls_session_t session; /* GnuTLS session handle */
|
gnutls_session_t session; /* GnuTLS session handle */
|
||||||
|
@ -415,6 +415,11 @@ ssl_init (void)
|
|||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void
|
||||||
|
ssl_cleanup (void)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
struct openssl_transport_context
|
struct openssl_transport_context
|
||||||
{
|
{
|
||||||
SSL *conn; /* SSL connection handle */
|
SSL *conn; /* SSL connection handle */
|
||||||
|
@ -33,6 +33,7 @@ as that of the covered work. */
|
|||||||
#define GEN_SSLFUNC_H
|
#define GEN_SSLFUNC_H
|
||||||
|
|
||||||
bool ssl_init (void);
|
bool ssl_init (void);
|
||||||
|
void ssl_cleanup (void);
|
||||||
bool ssl_connect_wget (int, const char *, int *);
|
bool ssl_connect_wget (int, const char *, int *);
|
||||||
bool ssl_check_certificate (int, const char *);
|
bool ssl_check_certificate (int, const char *);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user