wrappers/openssl: getOpenSSLVersion is gcsafe

Yet another weird {.gcsafe.} triggering when it shouldn't.
This commit is contained in:
Leorize 2020-06-04 00:12:26 -05:00 • committed by Andreas Rumpf
commit 61d4fbce4f

View file

@ -395,6 +395,7 @@ else:
proc getOpenSSLVersion*(): culong = proc getOpenSSLVersion*(): culong =
## Return OpenSSL version as unsigned long or 0 if not available ## Return OpenSSL version as unsigned long or 0 if not available
let theProc = cast[proc(): culong {.cdecl.}](sslSymNullable("OpenSSL_version_num")) let theProc = cast[proc(): culong {.cdecl.}](sslSymNullable("OpenSSL_version_num"))
{.gcsafe.}:
result = result =
if theProc.isNil: 0.culong if theProc.isNil: 0.culong
else: theProc() else: theProc()