From: Gerd Hoffmann Date: Mon, 7 Apr 2025 10:58:54 +0000 (+0200) Subject: crypto: disable OSSL_PARAM_REAL on UEFI X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=57f94478060faeb688ebbd9fde1aa73abae00636;p=thirdparty%2Fopenssl.git crypto: disable OSSL_PARAM_REAL on UEFI Floating point types like double can't be used on UEFI. Fix build on UEFI by disabling the OSSL_PARAM_REAL branch. Signed-off-by: Gerd Hoffmann Reviewed-by: Saša Nedvědický Reviewed-by: Tomas Mraz Reviewed-by: Matt Caswell (Merged from https://github.com/openssl/openssl/pull/27284) --- diff --git a/crypto/params_from_text.c b/crypto/params_from_text.c index 7532d4d4392..fb25400dc12 100644 --- a/crypto/params_from_text.c +++ b/crypto/params_from_text.c @@ -220,9 +220,9 @@ int OSSL_PARAM_print_to_bio(const OSSL_PARAM *p, BIO *bio, int print_values) BIGNUM *bn; #ifndef OPENSSL_SYS_UEFI double d; + int dok; #endif int ok = -1; - int dok; /* * Iterate through each key in the array printing its key and value @@ -280,16 +280,16 @@ int OSSL_PARAM_print_to_bio(const OSSL_PARAM *p, BIO *bio, int print_values) case OSSL_PARAM_OCTET_STRING: ok = BIO_dump(bio, (char *)p->data, p->data_size); break; +#ifndef OPENSSL_SYS_UEFI case OSSL_PARAM_REAL: dok = 0; -#ifndef OPENSSL_SYS_UEFI dok = OSSL_PARAM_get_double(p, &d); -#endif if (dok == 1) ok = BIO_printf(bio, "%f\n", d); else ok = BIO_printf(bio, "error getting value\n"); break; +#endif default: ok = BIO_printf(bio, "unknown type (%u) of %zu bytes\n", p->data_type, p->data_size);