sjpp / rpms / libvirt-python

Forked from rpms/libvirt-python 3 years ago
Clone
Blob Blame History Raw
From 997c203b6ae6cbf5dcb627d373a614bbe7d6e694 Mon Sep 17 00:00:00 2001
Message-Id: <997c203b6ae6cbf5dcb627d373a614bbe7d6e694@dist-git>
From: Peter Krempa <pkrempa@redhat.com>
Date: Mon, 24 Nov 2014 17:59:42 +0100
Subject: [PATCH] RHEL-only: downgrade version check for agent lifecycle event

https://bugzilla.redhat.com/show_bug.cgi?id=1167336

Makes the agent lifecycle event work.

Signed-off-by: Jiri Denemark <jdenemar@redhat.com>
---
 libvirt-override.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/libvirt-override.c b/libvirt-override.c
index c5d1478..3faddaa 100644
--- a/libvirt-override.c
+++ b/libvirt-override.c
@@ -6566,7 +6566,7 @@ libvirt_virConnectDomainEventTunableCallback(virConnectPtr conn ATTRIBUTE_UNUSED
 }
 #endif /* LIBVIR_CHECK_VERSION(1, 2, 8) */
 
-#if LIBVIR_CHECK_VERSION(1, 2, 11)
+#if LIBVIR_CHECK_VERSION(1, 2, 8)
 static int
 libvirt_virConnectDomainEventAgentLifecycleCallback(virConnectPtr conn ATTRIBUTE_UNUSED,
                                                     virDomainPtr dom,
@@ -6618,7 +6618,7 @@ libvirt_virConnectDomainEventAgentLifecycleCallback(virConnectPtr conn ATTRIBUTE
     return ret;
 
 }
-#endif /* LIBVIR_CHECK_VERSION(1, 2, 11) */
+#endif /* LIBVIR_CHECK_VERSION(1, 2, 8) */
 
 
 static PyObject *
@@ -6713,11 +6713,11 @@ libvirt_virConnectDomainEventRegisterAny(ATTRIBUTE_UNUSED PyObject *self,
         cb = VIR_DOMAIN_EVENT_CALLBACK(libvirt_virConnectDomainEventTunableCallback);
         break;
 #endif /* LIBVIR_CHECK_VERSION(1, 2, 8) */
-#if LIBVIR_CHECK_VERSION(1, 2, 11)
+#if LIBVIR_CHECK_VERSION(1, 2, 8)
     case VIR_DOMAIN_EVENT_ID_AGENT_LIFECYCLE:
         cb = VIR_DOMAIN_EVENT_CALLBACK(libvirt_virConnectDomainEventAgentLifecycleCallback);
         break;
-#endif /* LIBVIR_CHECK_VERSION(1, 2, 11) */
+#endif /* LIBVIR_CHECK_VERSION(1, 2, 8) */
     case VIR_DOMAIN_EVENT_ID_LAST:
         break;
     }
-- 
2.1.3