Skip to content

Commit

Permalink
check more NULL cases
Browse files Browse the repository at this point in the history
  • Loading branch information
samuel40791765 committed Jun 13, 2024
1 parent 261a5d9 commit f8cb242
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions crypto/x509/x509spki.c
Original file line number Diff line number Diff line change
Expand Up @@ -134,8 +134,9 @@ char *NETSCAPE_SPKI_b64_encode(NETSCAPE_SPKI *spki) {
}

int NETSCAPE_SPKI_print(BIO *out, NETSCAPE_SPKI *spki) {
if (out == NULL || spki == NULL || spki->spkac->pubkey == NULL ||
spki->sig_algor == NULL || spki->signature == NULL) {
if (out == NULL || spki == NULL || spki->spkac == NULL ||
spki->spkac->pubkey == NULL || spki->sig_algor == NULL ||
spki->sig_algor->algorithm == NULL || spki->signature == NULL) {
OPENSSL_PUT_ERROR(X509, ERR_R_PASSED_NULL_PARAMETER);
return 0;
}
Expand Down

0 comments on commit f8cb242

Please sign in to comment.