From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.groups.io with SMTP id smtpd.web11.15101.1678696233728732757 for ; Mon, 13 Mar 2023 01:30:34 -0700 Authentication-Results: mx.groups.io; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=OEyi869P; spf=pass (domain: redhat.com, ip: 170.10.129.124, mailfrom: kraxel@redhat.com) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1678696232; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=Xa/CijQ3/B+Pc+PKBdzkh/n8e/B9t8uLxsbKQERJwT0=; b=OEyi869P77stJrtAvLyv6EnftJii+elfkxF40G2VB1putLPmu5R3p0T5WG0n/SEr+ssF3d YAL9rURQga6Yh1xcg4leF2KBrwO2odSXBXzlsJLbZ50suQcKIpI9HUA2CEYRssj+NSpv70 nSE4Iq+tQ+JAnN9rHvYP9vDk76d0CLU= Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-49-sKf0CBisNqWr_IMj1B-Neg-1; Mon, 13 Mar 2023 04:30:28 -0400 X-MC-Unique: sKf0CBisNqWr_IMj1B-Neg-1 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.rdu2.redhat.com [10.11.54.8]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id B415485D183; Mon, 13 Mar 2023 08:30:27 +0000 (UTC) Received: from sirius.home.kraxel.org (unknown [10.39.192.142]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 7E83EC164E7; Mon, 13 Mar 2023 08:30:27 +0000 (UTC) Received: by sirius.home.kraxel.org (Postfix, from userid 1000) id 5FB0A1801E89; Mon, 13 Mar 2023 09:30:16 +0100 (CET) From: "Gerd Hoffmann" To: devel@edk2.groups.io Cc: Jian J Wang , Pawel Polawski , Xiaoyu Lu , Ard Biesheuvel , Guomin Jiang , Gerd Hoffmann , Jiewen Yao , Oliver Steffen , Jordan Justen Subject: [PATCH 10/22] CryptoPkg/TlsLib: ERR_GET_FUNC is gone Date: Mon, 13 Mar 2023 09:30:04 +0100 Message-Id: <20230313083016.136448-11-kraxel@redhat.com> In-Reply-To: <20230313083016.136448-1-kraxel@redhat.com> References: <20230313083016.136448-1-kraxel@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.8 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset="US-ASCII"; x-default=true Signed-off-by: Gerd Hoffmann --- CryptoPkg/Library/TlsLib/TlsConfig.c | 2 +- CryptoPkg/Library/TlsLib/TlsProcess.c | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/CryptoPkg/Library/TlsLib/TlsConfig.c b/CryptoPkg/Library/TlsLib/TlsConfig.c index 60559de4a7f3..37f6cfc27095 100644 --- a/CryptoPkg/Library/TlsLib/TlsConfig.c +++ b/CryptoPkg/Library/TlsLib/TlsConfig.c @@ -757,7 +757,7 @@ TlsSetCaCertificate ( // // Ignore "already in table" errors // - if (!((ERR_GET_FUNC (ErrorCode) == X509_F_X509_STORE_ADD_CERT) && + if (!((ERR_GET_LIB (ErrorCode) == ERR_LIB_X509) && (ERR_GET_REASON (ErrorCode) == X509_R_CERT_ALREADY_IN_HASH_TABLE))) { Status = EFI_ABORTED; diff --git a/CryptoPkg/Library/TlsLib/TlsProcess.c b/CryptoPkg/Library/TlsLib/TlsProcess.c index a803d86c4f4e..1d63d6268125 100644 --- a/CryptoPkg/Library/TlsLib/TlsProcess.c +++ b/CryptoPkg/Library/TlsLib/TlsProcess.c @@ -140,11 +140,10 @@ TlsDoHandshake ( DEBUG (( DEBUG_ERROR, - "%a ERROR 0x%x=L%x:F%x:R%x\n", + "%a ERROR 0x%x=L%x:R%x\n", __FUNCTION__, ErrorCode, ERR_GET_LIB (ErrorCode), - ERR_GET_FUNC (ErrorCode), ERR_GET_REASON (ErrorCode) )); } -- 2.39.2