From: Milan Broz Date: Wed, 22 Apr 2026 13:39:29 +0000 (+0200) Subject: Fix DSO symbol test with MINGW64 and pedantic warnings X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=26a269fe0077eab2cd55636cec366259cdef061f;p=thirdparty%2Fopenssl.git Fix DSO symbol test with MINGW64 and pedantic warnings GetProcAddress() cannot be simple cast to void* (SD_SYM) under strict warnigs, as it produces this error: ISO C forbids conversion of function pointer to object pointer type [-Werror=pedantic] Use common trick with cast to (uintptr_t). Reviewed-by: Tomas Mraz Reviewed-by: Eugene Syromiatnikov Reviewed-by: Norbert Pocs MergeDate: Thu Apr 30 11:42:33 2026 (Merged from https://github.com/openssl/openssl/pull/30941) --- diff --git a/test/simpledynamic.c b/test/simpledynamic.c index b3d3d2a59b7..5918797cd6a 100644 --- a/test/simpledynamic.c +++ b/test/simpledynamic.c @@ -52,7 +52,7 @@ int sd_load(const char *filename, SD *lib, ossl_unused int type) int sd_sym(SD lib, const char *symname, SD_SYM *sym) { - *sym = (SD_SYM)GetProcAddress(lib, symname); + *sym = (SD_SYM)(uintptr_t)GetProcAddress(lib, symname); return *sym != NULL; }