From 9b6e4d828a52bd8c11eeead1a39e7b9375abe4eb Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Mon, 31 Aug 2009 20:30:23 +0200 Subject: [PATCH] =?utf8?q?network=20plugin:=20Move=20the=20gcrypt=20initia?= =?utf8?q?lization=20into=20=E2=80=9Cnetwork=5Finit=E2=80=9D.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- src/network.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/network.c b/src/network.c index 791c1993..cf67c2bd 100644 --- a/src/network.c +++ b/src/network.c @@ -2938,6 +2938,12 @@ static int network_init (void) if (cache_flush_last != 0) return (0); +#if HAVE_LIBGCRYPT + gcry_control (GCRYCTL_SET_THREAD_CBS, &gcry_threads_pthread); + gcry_control (GCRYCTL_INIT_SECMEM, 32768, 0); + gcry_control (GCRYCTL_INITIALIZATION_FINISHED, 0); +#endif + plugin_register_shutdown ("network", network_shutdown); network_init_buffer (); @@ -3029,12 +3035,6 @@ static int network_flush (int timeout, void module_register (void) { -#if HAVE_LIBGCRYPT - gcry_control (GCRYCTL_SET_THREAD_CBS, &gcry_threads_pthread); - gcry_control (GCRYCTL_INIT_SECMEM, 32768, 0); - gcry_control (GCRYCTL_INITIALIZATION_FINISHED, 0); -#endif - plugin_register_complex_config ("network", network_config); plugin_register_init ("network", network_init); plugin_register_flush ("network", network_flush, -- 2.30.2