From: Alexandr Nedvedicky Date: Thu, 26 Feb 2026 10:21:14 +0000 (+0100) Subject: Coverity complains X509_REQ_set_subject_name() return value X-Git-Tag: openssl-4.0.0-alpha1~62 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=d6db53041186319bb0e6ca7b7ec00ad08d413bc7;p=thirdparty%2Fopenssl.git Coverity complains X509_REQ_set_subject_name() return value is ignored. Resolves: https://scan5.scan.coverity.com/#/project-view/62622/10222?selectedIssue=1201538 Reviewed-by: Eugene Syromiatnikov Reviewed-by: Paul Dale Reviewed-by: Nikola Pajkovsky Reviewed-by: Neil Horman MergeDate: Mon Mar 2 13:03:03 2026 (Merged from https://github.com/openssl/openssl/pull/30193) --- diff --git a/apps/ca.c b/apps/ca.c index c95ef2be4b7..2125ef597dc 100644 --- a/apps/ca.c +++ b/apps/ca.c @@ -1489,11 +1489,15 @@ static int do_body(X509 **xret, EVP_PKEY *pkey, X509 *x509, if (subj) { X509_NAME *n = parse_name(subj, chtype, multirdn, "subject"); + int ok_local; if (!n) goto end; - X509_REQ_set_subject_name(req, n); + + ok_local = X509_REQ_set_subject_name(req, n); X509_NAME_free(n); + if (ok_local == 0) + goto end; } if (default_op)