Fix error in description of 'oct' (issue 5678).
[python.git] / Python / sigcheck.c
blob022d0e8ac39016512901e5bb2adbfde259612efe
2 /* Sigcheck is similar to intrcheck() but sets an exception when an
3 interrupt occurs. It can't be in the intrcheck.c file since that
4 file (and the whole directory it is in) doesn't know about objects
5 or exceptions. It can't be in errors.c because it can be
6 overridden (at link time) by a more powerful version implemented in
7 signalmodule.c. */
9 #include "Python.h"
11 /* ARGSUSED */
12 int
13 PyErr_CheckSignals(void)
15 if (!PyOS_InterruptOccurred())
16 return 0;
17 PyErr_SetNone(PyExc_KeyboardInterrupt);
18 return -1;