bitkeeper revision 1.1389.1.16 (4273458eyxEjHSppjkQyDsXHHxOY9Q)

coredump.patch
Extend libxc and gdb server to coredump a domain.
Signed-off-by: Kip Macy <kmacy@fsmware.com>
This commit is contained in:
kaf24@firebug.cl.cam.ac.uk[kaf24] committed 2005-04-30 08:45:02 +00:00
1 parent 927084f0d4
commit b61e6cb4e9
10 files changed
+1134 -21

No files matched your search

+35
View File
@@ -36,6 +36,33 @@ typedef struct {
* Definitions for the 'xc' object type.
*/
static PyObject *pyxc_domain_dumpcore(PyObject *self,
PyObject *args,
PyObject *kwds)
{
XcObject *xc = (XcObject *)self;
u32 dom;
char *corefile;
static char *kwd_list[] = { "dom", "corefile", NULL };
if ( !PyArg_ParseTupleAndKeywords(args, kwds, "is", kwd_list, &dom, &corefile) )
goto exit;
if ( (corefile == NULL) || (corefile[0] == '\0') )
goto exit;
if ( xc_domain_dumpcore(xc->xc_handle, dom, corefile) != 0 )
return PyErr_SetFromErrno(xc_error);
Py_INCREF(zero);
return zero;
exit:
return NULL;
}
static PyObject *pyxc_domain_create(PyObject *self,
PyObject *args,
PyObject *kwds)
@@ -854,6 +881,14 @@ static PyMethodDef pyxc_methods[] = {
" mem_kb [int, 0]: Memory allocation, in kilobytes.\n"
"Returns: [int] new domain identifier; -1 on error.\n" },
{ "domain_dumpcore",
(PyCFunction)pyxc_domain_dumpcore,
METH_VARARGS | METH_KEYWORDS, "\n"
"dump core of a domain.\n"
" dom [int]: Identifier of domain to be paused.\n\n"
" corefile [string]: Name of corefile to be created.\n\n"
"Returns: [int] 0 on success; -1 on error.\n" },
{ "domain_pause",
(PyCFunction)pyxc_domain_pause,
METH_VARARGS | METH_KEYWORDS, "\n"
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.