This is the mail archive of the
cygwin-patches
mailing list for the Cygwin project.
[PATCH] Cygwin: Fix return value of sched_getaffinity
- From: Mark Geisert <mark at maxrnd dot com>
- To: cygwin-patches at cygwin dot com
- Cc: Mark Geisert <mark at maxrnd dot com>
- Date: Mon, 24 Jun 2019 22:25:23 -0700
- Subject: [PATCH] Cygwin: Fix return value of sched_getaffinity
Return what the documentation says, instead of a misreading of it.
---
winsup/cygwin/sched.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/winsup/cygwin/sched.cc b/winsup/cygwin/sched.cc
index e7b44d319..8f24bf80d 100644
--- a/winsup/cygwin/sched.cc
+++ b/winsup/cygwin/sched.cc
@@ -608,7 +608,7 @@ done:
else
{
/* Emulate documented Linux kernel behavior on successful return */
- status = wincap.cpu_count ();
+ status = sizeof (cpu_set_t);
}
return status;
}
--
2.21.0