Fix a bug when calculating remnant size.
This commit is contained in:
parent
d7aa5242c5
commit
8a18c0d3c8
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=176864
@ -602,7 +602,7 @@ _pthread_attr_setaffinity_np(pthread_attr_t *pattr, size_t cpusetsize,
|
||||
attr->cpusetsize = cpusetsize;
|
||||
} else {
|
||||
memset(((char *)attr->cpuset) + cpusetsize, 0,
|
||||
cpusetsize - attr->cpusetsize);
|
||||
attr->cpusetsize - cpusetsize);
|
||||
attr->cpusetsize = cpusetsize;
|
||||
}
|
||||
memcpy(attr->cpuset, cpuset, cpusetsize);
|
||||
|
Loading…
Reference in New Issue
Block a user