Fixed scan-build error with possibly using a NULL pointer.
This commit is contained in:
parent
0f93b86b61
commit
c863300805
@ -10063,7 +10063,7 @@ WOLFSSL_X509* wolfSSL_X509_load_certificate_file(const char* fname, int format)
|
||||
|
||||
/* At this point we want `der` to have the certificate in DER format */
|
||||
/* ready to be decoded. */
|
||||
if (der->buffer != NULL) {
|
||||
if (der != NULL && der->buffer != NULL) {
|
||||
#ifdef WOLFSSL_SMALL_STACK
|
||||
DecodedCert* cert = NULL;
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user