[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [libvirt] [PATCH 1/2] rpc: convert unknown procedures to VIR_ERR_NO_SUPPORT



On 09/14/2011 12:51 PM, Eric Blake wrote:
Libvirt special-cases a specific VIR_ERR_RPC from the remote driver
back into VIR_ERR_NO_SUPPORT on the client, so that clients can
handle missing rpc functions the same whether the hypervisor driver
is local or remote.  However, commit c1b22644 introduced a regression:
VIR_FROM_THIS changed from VIR_FROM_REMOTE to VIR_FROM_RPC, so the
special casing no longer works if the server uses the newer error
domain.

* src/rpc/virnetclientprogram.c
(virNetClientProgramDispatchError): Also cater to 0.9.3 and newer.
---
  src/rpc/virnetclientprogram.c |    2 +-
  1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/src/rpc/virnetclientprogram.c b/src/rpc/virnetclientprogram.c
index a07b744..33fa507 100644
--- a/src/rpc/virnetclientprogram.c
+++ b/src/rpc/virnetclientprogram.c
@@ -151,7 +151,7 @@ virNetClientProgramDispatchError(virNetClientProgramPtr prog ATTRIBUTE_UNUSED,
          break;
      }

-    if (err.domain == VIR_FROM_REMOTE&&
+    if ((err.domain == VIR_FROM_REMOTE || err.domain == VIR_FROM_RPC)&&

This is a regression fix, and I got approval on IRC, so I'm pushing now to be part of rc3:

<eblake> danpb: have you seen this rpc regression bug fix? https://www.redhat.com/archives/libvir-list/2011-September/msg00547.html <supybot> Title: [libvirt] [PATCH 1/2] rpc: convert unknown procedures to VIR_ERR_NO_SUPP (at www.redhat.com)
<danpb>	eblake: yeah looks ok

--
Eric Blake   eblake redhat com    +1-801-349-2682
Libvirt virtualization library http://libvirt.org


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]