From a28876d013accb785592925a13160b6ef7d4fa60 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Fri, 22 Jun 2007 22:13:52 +0000 Subject: [PATCH] (pthread_getattr_np): Clear cpuset and cpusetsize if pthread_getaffinity_np failed with ENOSYS. --- nptl/pthread_getattr_np.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/nptl/pthread_getattr_np.c b/nptl/pthread_getattr_np.c index 9c0e4ed866..87cf56482f 100644 --- a/nptl/pthread_getattr_np.c +++ b/nptl/pthread_getattr_np.c @@ -164,8 +164,12 @@ pthread_getattr_np (thread_id, attr) { free (cpuset); if (ret == ENOSYS) - /* There is no such functionality. */ - ret = 0; + { + /* There is no such functionality. */ + ret = 0; + iattr->cpuset = NULL; + iattr->cpusetsize = 0; + } } } -- 2.11.4.GIT