My previous patch 74c75671331d284e1f777f9692b72e9737520bf0
introduced a regression by removing TLS initialization from client.
---
diff to v1:
-remove virNetTLSDeinit()
daemon/libvirtd.c | 2 --
src/libvirt.c | 3 +++
src/rpc/virnettlscontext.c | 8 --------
src/rpc/virnettlscontext.h | 1 -
4 files changed, 3 insertions(+), 11 deletions(-)
diff --git a/daemon/libvirtd.c b/daemon/libvirtd.c
index 5969a82..423c3d7 100644
--- a/daemon/libvirtd.c
+++ b/daemon/libvirtd.c
@@ -1516,7 +1516,6 @@ int main(int argc, char **argv) {
virHookCall(VIR_HOOK_DRIVER_DAEMON, "-", VIR_HOOK_DAEMON_OP_START,
0, "start", NULL);
- virNetTLSInit();
if (daemonSetupNetworking(srv, config,
sock_file, sock_file_ro,
ipsock, privileged) < 0) {
@@ -1555,7 +1554,6 @@ cleanup:
virNetServerProgramFree(qemuProgram);
virNetServerClose(srv);
virNetServerFree(srv);
- virNetTLSDeinit();
if (statuswrite != -1) {
if (ret != 0) {
/* Tell parent of daemon what failed */
diff --git a/src/libvirt.c b/src/libvirt.c
index c8af3e1..fdf3923 100644
--- a/src/libvirt.c
+++ b/src/libvirt.c
@@ -40,6 +40,7 @@
#include "memory.h"
#include "configmake.h"
#include "intprops.h"
+#include "rpc/virnettlscontext.h"
#ifndef WITH_DRIVER_MODULES
# ifdef WITH_TEST
@@ -409,6 +410,8 @@ virInitialize(void)
virLogSetFromEnv();
+ virNetTLSInit();
+
VIR_DEBUG("register drivers");
#if HAVE_WINSOCK2_H
diff --git a/src/rpc/virnettlscontext.c b/src/rpc/virnettlscontext.c
index 8482eaf..e901b63 100644
--- a/src/rpc/virnettlscontext.c
+++ b/src/rpc/virnettlscontext.c
@@ -1410,11 +1410,3 @@ void virNetTLSInit(void)
{
gnutls_global_init();
}
-
-/*
- * See virNetTLSInit
- */
-void virNetTLSDeinit(void)
-{
- gnutls_global_deinit();
-}
diff --git a/src/rpc/virnettlscontext.h b/src/rpc/virnettlscontext.h
index 99f31b9..fdfce6d 100644
--- a/src/rpc/virnettlscontext.h
+++ b/src/rpc/virnettlscontext.h
@@ -31,7 +31,6 @@ typedef virNetTLSSession *virNetTLSSessionPtr;
void virNetTLSInit(void);
-void virNetTLSDeinit(void);
virNetTLSContextPtr virNetTLSContextNewServerPath(const char *pkipath,
bool tryUserPkiPath,
--
1.7.3.4
Show replies by date
On 08/24/2011 09:18 AM, Michal Privoznik wrote:
My previous patch 74c75671331d284e1f777f9692b72e9737520bf0
introduced a regression by removing TLS initialization from client.
---
diff to v1:
-remove virNetTLSDeinit()
daemon/libvirtd.c | 2 --
src/libvirt.c | 3 +++
src/rpc/virnettlscontext.c | 8 --------
src/rpc/virnettlscontext.h | 1 -
4 files changed, 3 insertions(+), 11 deletions(-)
ACK.
I was a bit surprised that you did not have to modify
src/libvirt_private.syms, but a grep confirmed that you got all traces
of virNetTLSDeinit.
--
Eric Blake eblake(a)redhat.com +1-801-349-2682
Libvirt virtualization library
http://libvirt.org