diff --git a/agent/gpg-agent.c b/agent/gpg-agent.c --- a/agent/gpg-agent.c +++ b/agent/gpg-agent.c @@ -966,6 +966,7 @@ initialize_modules (void) { thread_init_once (); + assuan_set_system_hooks (ASSUAN_SYSTEM_NPTH); initialize_module_cache (); initialize_module_call_pinentry (); initialize_module_call_scd (); @@ -1026,8 +1027,8 @@ malloc_hooks.free = gcry_free; assuan_set_malloc_hooks (&malloc_hooks); assuan_set_gpg_err_source (GPG_ERR_SOURCE_DEFAULT); - assuan_set_system_hooks (ASSUAN_SYSTEM_NPTH); assuan_sock_init (); + assuan_sock_set_system_hooks (ASSUAN_SYSTEM_NPTH); setup_libassuan_logging (&opt.debug, NULL); setup_libgcrypt_logging ();