* [PATCH] minios xc_evtchn_unbind missing return
@ 2008-07-31 23:48 Diego Ongaro
0 siblings, 0 replies; only message in thread
From: Diego Ongaro @ 2008-07-31 23:48 UTC (permalink / raw)
To: xen-devel
minios: Error case when unbinding unknown port in xc_evtchn_unbind is
missing a return statement.
Signed-off-by: Diego Ongaro <diego.ongaro@citrix.com>
---
diff --git a/tools/libxc/xc_minios.c b/tools/libxc/xc_minios.c
--- a/tools/libxc/xc_minios.c
+++ b/tools/libxc/xc_minios.c
@@ -259,8 +259,11 @@ int xc_evtchn_unbind(int xce_handle, evt
files[xce_handle].evtchn.ports[i].port = -1;
break;
}
- if (i == MAX_EVTCHN_PORTS)
+ if (i == MAX_EVTCHN_PORTS) {
printf("Warning: couldn't find port %"PRId32" for xc handle %x\n", port, xce_handle);
+ errno = -EINVAL;
+ return -1;
+ }
files[xce_handle].evtchn.ports[i].bound = 0;
unbind_evtchn(port);
return 0;
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-07-31 23:48 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-07-31 23:48 [PATCH] minios xc_evtchn_unbind missing return Diego Ongaro
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.