Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix mismatch of OpenSSL function signatures that cause errors with gc…
…c-14 Building with gcc-14 fails with diagnostics like this: ``` src/tpm2-tss-engine-rsa.c:805:46: error: passing argument 2 of 'EVP_PKEY_meth_set_copy' from incompatible pointer type [-Wincompatible-pointer-types] 805 | EVP_PKEY_meth_set_copy(pkey_rsa_methods, rsa_pkey_copy); | ^~~~~~~~~~~~~ | | | int (*)(EVP_PKEY_CTX *, EVP_PKEY_CTX *) {aka int (*)(struct evp_pkey_ctx_st *, struct evp_pkey_ctx_st *)} /usr/include/openssl/evp.h:2005:36: note: expected 'int (*)(EVP_PKEY_CTX *, const EVP_PKEY_CTX *)' {aka 'int (*)(struct evp_pkey_ctx_st *, const struct evp_pkey_ctx_st *)'} but argument is of type 'int (*)(EVP_PKEY_CTX *, EVP_PKEY_CTX *)' {aka 'int (*)(struct evp_pkey_ctx_st *, struct evp_pkey_ctx_st *)'} ``` A look into OpenSSL upstream shows that these functions have always had const `src` parameters. Thus this error was simply not detected by earlier compiler versions. Signed-off-by: Matthias Gerstner <[email protected]>
- Loading branch information