]> git.ipfire.org Git - thirdparty/openssl.git/commitdiff
resolve defects: reverse_inull; row[DB_exp_date] referenced before checking
authorxuyunjia <yunjiaxu_sse@163.com>
Sun, 18 Oct 2020 15:33:54 +0000 (23:33 +0800)
committerMatt Caswell <matt@openssl.org>
Tue, 20 Oct 2020 13:37:21 +0000 (14:37 +0100)
Reviewed-by: Tomas Mraz <tmraz@fedoraproject.org>
Reviewed-by: Matt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/13170)

(cherry picked from commit 6a13c9c9842f54ed8d98c6f37cc4ae6c1cde8b7a)

apps/ca.c [changed mode: 0644->0755]

old mode 100644 (file)
new mode 100755 (executable)
index a4a7712..1b38de3
--- a/apps/ca.c
+++ b/apps/ca.c
@@ -1862,8 +1862,8 @@ static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509,
     row[DB_exp_date][tm->length] = '\0';
     row[DB_rev_date] = NULL;
     row[DB_file] = OPENSSL_strdup("unknown");
-    if ((row[DB_type] == NULL) || (row[DB_exp_date] == NULL) ||
-        (row[DB_file] == NULL) || (row[DB_name] == NULL)) {
+    if ((row[DB_type] == NULL) || (row[DB_file] == NULL)
+        || (row[DB_name] == NULL)) {
         BIO_printf(bio_err, "Memory allocation failure\n");
         goto end;
     }