[gnutls-devel] GnuTLS | nettle's gnutls_crypto_init() causes segfault in unrelated gmp code during static destructors (#1398)

Read-only notification of GnuTLS library development activities gnutls-devel at lists.gnutls.org
Sat Aug 20 04:22:32 CEST 2022

Luke D'Alessandro commented:

Actually I take it back, I can't workaround this by resetting GMP's allocators to their defaults, as those defaults are not visible in `gmp.h`. I can set them to `NULL`, which is probably fine but will show up as leaked memory in various tools, or I think I can hope that they're malloc/realloc/free, and write my own interposition functions to forward to those.

Neither one of these is really compelling.

Also, I should note this isn't a C++-only issue, any sort of `__attribute__((destructor))` can run into this.

Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/issues/1398#note_1071172363
You're receiving this email because of your account on gitlab.com.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.gnupg.org/pipermail/gnutls-devel/attachments/20220820/d2d674d9/attachment.html>

More information about the Gnutls-devel mailing list