EVTCHNOP_alloc_unbound can allocate a port in an arbitrary

domain (only if the caller is sufficiently privileged).

Signed-off-by: Keir Fraser <keir@xensource.com>
This commit is contained in:
kaf24@firebug.cl.cam.ac.uk committed 2005-10-05 19:14:13 +01:00
1 parent a00e0c297c
commit 0f742e92ea
8 files changed
+49 -20

No files matched your search

+5 -5
View File
@@ -432,16 +432,16 @@ static PyObject *pyxc_evtchn_alloc_unbound(PyObject *self,
{
XcObject *xc = (XcObject *)self;
u32 dom;
u32 dom = DOMID_SELF, remote_dom;
int port = 0;
static char *kwd_list[] = { "dom", "port", NULL };
static char *kwd_list[] = { "remote_dom", "dom", "port", NULL };
if ( !PyArg_ParseTupleAndKeywords(args, kwds, "i|i", kwd_list,
&dom, &port) )
if ( !PyArg_ParseTupleAndKeywords(args, kwds, "i|ii", kwd_list,
&remote_dom, &dom, &port) )
return NULL;
if ( xc_evtchn_alloc_unbound(xc->xc_handle, dom, &port) != 0 )
if ( xc_evtchn_alloc_unbound(xc->xc_handle, remote_dom, dom, &port) != 0 )
return PyErr_SetFromErrno(xc_error);
return PyInt_FromLong(port);
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.