]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
gh-102336: Ensure CancelIoEx result is not ignored (GH-102347)
authorMax Bachmann <kontakt@maxbachmann.de>
Wed, 1 Mar 2023 12:01:39 +0000 (13:01 +0100)
committerGitHub <noreply@github.com>
Wed, 1 Mar 2023 12:01:39 +0000 (12:01 +0000)
fix ignored return value

Modules/_winapi.c

index 8c4c725b9df2564063ec128ecfc683c51f533d2a..eefc2571ee8287d3402d1c503f739f69318af8f0 100644 (file)
@@ -288,7 +288,7 @@ _winapi_Overlapped_cancel_impl(OverlappedObject *self)
 
     if (self->pending) {
         Py_BEGIN_ALLOW_THREADS
-        CancelIoEx(self->handle, &self->overlapped);
+        res = CancelIoEx(self->handle, &self->overlapped);
         Py_END_ALLOW_THREADS
     }