163057e
From 213f38dc580d39f2cb46592b5e6db585fc6a650f Mon Sep 17 00:00:00 2001
163057e
From: rpm-build <rpm-build>
163057e
Date: Mon, 31 Jul 2023 09:41:28 +0200
163057e
Subject: [PATCH 19/35] 0035-speed-skip-unavailable-dgst.patch
163057e
163057e
Patch-name: 0035-speed-skip-unavailable-dgst.patch
163057e
Patch-id: 35
163057e
Patch-status: |
163057e
    # Skip unavailable algorithms running `openssl speed`
163057e
From-dist-git-commit: 9409bc7044cf4b5773639cce20f51399888c45fd
163057e
---
163057e
 apps/speed.c | 3 +++
163057e
 1 file changed, 3 insertions(+)
163057e
163057e
diff --git a/apps/speed.c b/apps/speed.c
163057e
index d527f12f18..2ff3eb53bd 100644
163057e
--- a/apps/speed.c
163057e
+++ b/apps/speed.c
163057e
@@ -610,6 +610,9 @@ static int EVP_MAC_loop(int algindex, void *args)
163057e
     for (count = 0; COND(c[algindex][testnum]); count++) {
163057e
         size_t outl;
163057e
 
163057e
+        if (mctx == NULL)
163057e
+            return -1;
163057e
+
163057e
         if (!EVP_MAC_init(mctx, NULL, 0, NULL)
163057e
             || !EVP_MAC_update(mctx, buf, lengths[testnum])
163057e
             || !EVP_MAC_final(mctx, mac, &outl, sizeof(mac)))
163057e
-- 
163057e
2.41.0
163057e