MbedTLS: Correct NULL checks for functions in line with other backends
This commit is contained in:
parent
988fedf212
commit
ac62792970
1 changed files with 4 additions and 1 deletions
|
@ -534,6 +534,9 @@ rb_get_ssl_strerror(rb_fde_t *const F)
|
||||||
int
|
int
|
||||||
rb_get_ssl_certfp(rb_fde_t *const F, uint8_t certfp[const RB_SSL_CERTFP_LEN], int method)
|
rb_get_ssl_certfp(rb_fde_t *const F, uint8_t certfp[const RB_SSL_CERTFP_LEN], int method)
|
||||||
{
|
{
|
||||||
|
if(F == NULL || F->ssl == NULL)
|
||||||
|
return 0;
|
||||||
|
|
||||||
mbedtls_md_type_t md_type;
|
mbedtls_md_type_t md_type;
|
||||||
int hashlen;
|
int hashlen;
|
||||||
|
|
||||||
|
@ -590,7 +593,7 @@ rb_get_ssl_info(char *const buf, size_t len)
|
||||||
const char *
|
const char *
|
||||||
rb_ssl_get_cipher(rb_fde_t *const F)
|
rb_ssl_get_cipher(rb_fde_t *const F)
|
||||||
{
|
{
|
||||||
if(F == NULL || F->ssl == NULL || SSL_P(F) == NULL)
|
if(F == NULL || F->ssl == NULL)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
static char buf[512];
|
static char buf[512];
|
||||||
|
|
Loading…
Reference in a new issue