* src/xs_internal.c: fix xen events handling problem (Dan Berrange)

Daniel
This commit is contained in:
Daniel Veillard 2009-03-11 13:43:24 +00:00
parent 27a63a76af
commit bdd6894713
2 changed files with 10 additions and 2 deletions

View File

@ -1,3 +1,7 @@
Wed Mar 11 14:42:24 CET 2009 Daniel Veillard <veilard@redhat.com>
* src/xs_internal.c: fix xen events handling problem (Dan Berrange)
Tue Mar 10 12:03:37 CET 2009 Daniel Veillard <veilard@redhat.com>
* src/xend_internal.c: fix an allocation problem in

View File

@ -1215,7 +1215,7 @@ xenStoreFindWatch(xenStoreWatchListPtr list,
static void
xenStoreWatchEvent(int watch ATTRIBUTE_UNUSED,
int fd ATTRIBUTE_UNUSED,
int events ATTRIBUTE_UNUSED,
int events,
void *data)
{
char **event;
@ -1226,8 +1226,12 @@ xenStoreWatchEvent(int watch ATTRIBUTE_UNUSED,
virConnectPtr conn = data;
xenUnifiedPrivatePtr priv = (xenUnifiedPrivatePtr) conn->privateData;
if(!priv) return;
/* only set a watch on read and write events */
if (events & (VIR_EVENT_HANDLE_ERROR | VIR_EVENT_HANDLE_HANGUP)) return;
xenUnifiedLock(priv);
if(!priv->xshandle)