mirror of
https://gitlab.com/openconnect/ocserv.git
synced 2026-02-10 16:57:00 +08:00
avoid deinitializing garbage
This commit is contained in:
@@ -258,7 +258,7 @@ int ret;
|
||||
static void certificate_check(main_server_st *s)
|
||||
{
|
||||
gnutls_datum_t data;
|
||||
gnutls_x509_crt_t crt;
|
||||
gnutls_x509_crt_t crt = NULL;
|
||||
int ret;
|
||||
unsigned usage;
|
||||
|
||||
@@ -292,7 +292,8 @@ unsigned usage;
|
||||
}
|
||||
|
||||
cleanup:
|
||||
gnutls_x509_crt_deinit(crt);
|
||||
if (crt != NULL)
|
||||
gnutls_x509_crt_deinit(crt);
|
||||
gnutls_free(data.data);
|
||||
return;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user