]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
bpo-33608: Fix PyEval_InitThreads() warning (GH-12346)
authorVictor Stinner <vstinner@redhat.com>
Fri, 15 Mar 2019 15:04:20 +0000 (16:04 +0100)
committerGitHub <noreply@github.com>
Fri, 15 Mar 2019 15:04:20 +0000 (16:04 +0100)
The function has no return value.

Fix the following warning on Windows:

    python\ceval.c(180): warning C4098: 'PyEval_InitThreads':
    'void' function returning a value

Python/ceval.c

index 373cde9a17bba328b02009d22f645467c08e6871..dd8826bf9c83f93ad11a4699a24d367d7721f62f 100644 (file)
@@ -177,7 +177,7 @@ PyEval_InitThreads(void)
 
     _PyRuntime.ceval.pending.lock = PyThread_allocate_lock();
     if (_PyRuntime.ceval.pending.lock == NULL) {
-        return Py_FatalError("Can't initialize threads for pending calls");
+        Py_FatalError("Can't initialize threads for pending calls");
     }
 }