Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 10 additions & 0 deletions Doc/c-api/sys.rst
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,16 @@ Operating System Utilities
This is a thin wrapper around either :c:func:`!sigaction` or :c:func:`!signal`. Do
not call those functions directly!


.. c:function:: int PyOS_InterruptOccurred(void)
Comment thread
StanFromIreland marked this conversation as resolved.

Check if a :c:macro:`!SIGINT` signal has been received.
Returns ``1`` if a :c:macro:`!SIGINT` has occurred and clears the signal flag,
or ``0`` otherwise.
Comment thread
StanFromIreland marked this conversation as resolved.

The caller must hold an :term:`attached thread state`.


Comment thread
StanFromIreland marked this conversation as resolved.
Outdated
.. c:function:: wchar_t* Py_DecodeLocale(const char* arg, size_t *size)

.. warning::
Expand Down
2 changes: 1 addition & 1 deletion Modules/signalmodule.c
Original file line number Diff line number Diff line change
Expand Up @@ -2025,7 +2025,7 @@ _PyOS_InterruptOccurred(PyThreadState *tstate)
}


// The caller must to hold the GIL
// The caller must hold the GIL
Comment thread
StanFromIreland marked this conversation as resolved.
Outdated
int
PyOS_InterruptOccurred(void)
{
Expand Down
Loading