This is an archived copy of the Xen.org mailing list, which we have preserved to ensure that existing links to archives are not broken. The live archive, which contains the latest emails, can be found at http://lists.xen.org/
Home Products Support Community News


[Xen-changelog] [xen-unstable] XendAPIStore - do not remove non-existent

To: xen-changelog@xxxxxxxxxxxxxxxxxxx
Subject: [Xen-changelog] [xen-unstable] XendAPIStore - do not remove non-existent item
From: Xen patchbot-unstable <patchbot-unstable@xxxxxxxxxxxxxxxxxxx>
Date: Wed, 04 Feb 2009 07:10:19 -0800
Delivery-date: Wed, 04 Feb 2009 07:10:00 -0800
Envelope-to: www-data@xxxxxxxxxxxxxxxxxxx
List-help: <mailto:xen-changelog-request@lists.xensource.com?subject=help>
List-id: BK change log <xen-changelog.lists.xensource.com>
List-post: <mailto:xen-changelog@lists.xensource.com>
List-subscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=subscribe>
List-unsubscribe: <http://lists.xensource.com/mailman/listinfo/xen-changelog>, <mailto:xen-changelog-request@lists.xensource.com?subject=unsubscribe>
Reply-to: xen-devel@xxxxxxxxxxxxxxxxxxx
Sender: xen-changelog-bounces@xxxxxxxxxxxxxxxxxxx
# HG changeset patch
# User Keir Fraser <keir.fraser@xxxxxxxxxx>
# Date 1233748637 0
# Node ID 861ebefa7f396c43c02a47f0bb9977f88dbc9f1b
# Parent  c3b5e36248c94d43a1619201de114fd84135a20c
XendAPIStore - do not remove non-existent item

If list is searched and item not found, then don't attempt to delete
the item.

Signed-off-by: Jim Fehlig <jfehlig@xxxxxxxxxx>
 tools/python/xen/xend/XendAPIStore.py |    3 ++-
 1 files changed, 2 insertions(+), 1 deletion(-)

diff -r c3b5e36248c9 -r 861ebefa7f39 tools/python/xen/xend/XendAPIStore.py
--- a/tools/python/xen/xend/XendAPIStore.py     Tue Feb 03 18:14:19 2009 +0000
+++ b/tools/python/xen/xend/XendAPIStore.py     Wed Feb 04 11:57:17 2009 +0000
@@ -33,7 +33,8 @@ def register(uuid, type, inst):
 def deregister(uuid, type):
     old = get(uuid, type)
-    del __classes[(uuid, type)]
+    if old is not None:
+        del __classes[(uuid, type)]
     return old
 def get(uuid, type):

Xen-changelog mailing list

<Prev in Thread] Current Thread [Next in Thread>
  • [Xen-changelog] [xen-unstable] XendAPIStore - do not remove non-existent item, Xen patchbot-unstable <=