summaryrefslogtreecommitdiffstats
path: root/Modules/clinic/signalmodule.c.h
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2017-10-13 20:49:43 (GMT)
committerGitHub <noreply@github.com>2017-10-13 20:49:43 (GMT)
commitef611c96eab0ab667ebb43fdf429b319f6d99890 (patch)
tree39623a7ea31b55dc13dfc2a5d3955ff7ae77e537 /Modules/clinic/signalmodule.c.h
parenta505ecdc5013cd8f930aacc1ec4fb2afa62d3853 (diff)
downloadcpython-ef611c96eab0ab667ebb43fdf429b319f6d99890.zip
cpython-ef611c96eab0ab667ebb43fdf429b319f6d99890.tar.gz
cpython-ef611c96eab0ab667ebb43fdf429b319f6d99890.tar.bz2
bpo-30807: signal.setitimer() now uses _PyTime API (GH-3865)
The _PyTime API handles detects overflow and is well tested. Document that the signal will only be sent once if internal is equal to zero.
Diffstat (limited to 'Modules/clinic/signalmodule.c.h')
-rw-r--r--Modules/clinic/signalmodule.c.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/Modules/clinic/signalmodule.c.h b/Modules/clinic/signalmodule.c.h
index a4542cc..cc3e640 100644
--- a/Modules/clinic/signalmodule.c.h
+++ b/Modules/clinic/signalmodule.c.h
@@ -182,18 +182,18 @@ PyDoc_STRVAR(signal_setitimer__doc__,
{"setitimer", (PyCFunction)signal_setitimer, METH_FASTCALL, signal_setitimer__doc__},
static PyObject *
-signal_setitimer_impl(PyObject *module, int which, double seconds,
- double interval);
+signal_setitimer_impl(PyObject *module, int which, PyObject *seconds,
+ PyObject *interval);
static PyObject *
signal_setitimer(PyObject *module, PyObject **args, Py_ssize_t nargs)
{
PyObject *return_value = NULL;
int which;
- double seconds;
- double interval = 0.0;
+ PyObject *seconds;
+ PyObject *interval = NULL;
- if (!_PyArg_ParseStack(args, nargs, "id|d:setitimer",
+ if (!_PyArg_ParseStack(args, nargs, "iO|O:setitimer",
&which, &seconds, &interval)) {
goto exit;
}
@@ -440,4 +440,4 @@ exit:
#ifndef SIGNAL_PTHREAD_KILL_METHODDEF
#define SIGNAL_PTHREAD_KILL_METHODDEF
#endif /* !defined(SIGNAL_PTHREAD_KILL_METHODDEF) */
-/*[clinic end generated code: output=3f6e6298696f1b75 input=a9049054013a1b77]*/
+/*[clinic end generated code: output=a003d3fea9a33daa input=a9049054013a1b77]*/