[gnutls-devel] GnuTLS | pkcs11: try to initialize modules in thread-safe mode (!2014)
Read-only notification of GnuTLS library development activities
gnutls-devel at lists.gnutls.org
Wed Sep 10 13:40:17 CEST 2025
Alexander Sosedkin started a new discussion on lib/pkcs11.c: https://gitlab.com/gnutls/gnutls/-/merge_requests/2014#note_2741867603
>
> memset(&info, 0, sizeof(info));
> - pkcs11_get_module_info(module, &info);
> + pkcs11_get_module_info(provider->module, &info);
>
> /* initially check if this module is a duplicate */
> for (i = 0; i < active_providers; i++) {
> /* already loaded, skip the rest */
> - if (module == providers[i].module ||
> + if (provider->module == providers[i].module ||
> memcmp(&info, &providers[i].info, sizeof(info)) == 0) {
> + char *name = p11_kit_module_get_name(provider->module);
> _gnutls_debug_log("p11: module %s is already loaded.\n",
> name);
> + free(name);
> return GNUTLS_E_INT_RET_0;
what is that return code? is that a success or not? one of the two callees turns that into a 0, one does not...
--
Reply to this email directly or view it on GitLab: https://gitlab.com/gnutls/gnutls/-/merge_requests/2014#note_2741867603
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/20250910/0cd6e8ca/attachment-0001.html>
More information about the Gnutls-devel
mailing list