Commit 833518cf authored by Kurt Cancemi's avatar Kurt Cancemi Committed by Matt Caswell
Browse files

Add missing NULL check in X509V3_parse_list()



Matt's note: I added a call to X509V3err to Kurt's original patch.

RT#3840

Signed-off-by: default avatarMatt Caswell <matt@openssl.org>
Reviewed-by: default avatarRich Salz <rsalz@openssl.org>
(cherry picked from commit 344c271e)
parent 8a73e3a0
Loading
Loading
Loading
Loading
+4 −0
Original line number Diff line number Diff line
@@ -285,6 +285,10 @@ STACK_OF(CONF_VALUE) *X509V3_parse_list(const char *line)
    int state;
    /* We are going to modify the line so copy it first */
    linebuf = BUF_strdup(line);
    if (linebuf == NULL) {
        X509V3err(X509V3_F_X509V3_PARSE_LIST, ERR_R_MALLOC_FAILURE);
        goto err;
    }
    state = HDR_NAME;
    ntmp = NULL;
    /* Go through all characters */