This is the mail archive of the cygwin-patches mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]