From 02de8979ccc09d1ef5162f64dbc9e546dae2da4e Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 19 Dec 2007 19:41:06 +0000 Subject: Patch #1583 by Adam Olsen. This adds signal.set_wakeup_fd(fd) which sets a file descriptor to which a zero byte will be written whenever a C exception handler runs. I added a simple C API as well, PySignal_SetWakeupFd(fd). --- Include/pyerrors.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'Include/pyerrors.h') diff --git a/Include/pyerrors.h b/Include/pyerrors.h index a6ee840e23..73a0e36288 100644 --- a/Include/pyerrors.h +++ b/Include/pyerrors.h @@ -238,6 +238,9 @@ PyAPI_FUNC(int) PyErr_WarnExplicit(PyObject *, const char *, PyAPI_FUNC(int) PyErr_CheckSignals(void); PyAPI_FUNC(void) PyErr_SetInterrupt(void); +/* In signalmodule.c */ +int PySignal_SetWakeupFd(int fd); + /* Support for adding program text to SyntaxErrors */ PyAPI_FUNC(void) PyErr_SyntaxLocation(const char *, int); PyAPI_FUNC(PyObject *) PyErr_ProgramText(const char *, int); -- cgit v1.2.1