Skip to content

Commit b4e096a

Browse files
Review
1 parent 56cc384 commit b4e096a

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

Doc/c-api/sys.rst

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -127,18 +127,19 @@ Operating System Utilities
127127
.. c:function:: int PyOS_InterruptOccurred(void)
128128
129129
Check if a :c:macro:`!SIGINT` signal has been received.
130+
130131
Returns ``1`` if a :c:macro:`!SIGINT` has occurred and clears the signal flag,
131132
or ``0`` otherwise.
132133
133-
This function is async-signal-safe and this function cannot fail.
134-
The caller must hold an :term:`attached thread state`.
135-
136134
In most cases, you should prefer :c:func:`PyErr_CheckSignals` over this function.
137135
:c:func:`!PyErr_CheckSignals` invokes the appropriate signal handlers
138136
for all pending signals, allowing Python code to handle the signal properly.
139137
This function only detects :c:macro:`!SIGINT` and does not invoke any Python
140138
signal handlers.
141139
140+
This function is async-signal-safe and this function cannot fail.
141+
The caller must hold an :term:`attached thread state`.
142+
142143
143144
.. c:function:: wchar_t* Py_DecodeLocale(const char* arg, size_t *size)
144145

0 commit comments

Comments
 (0)