diff options
Diffstat (limited to 'sysdeps')
-rw-r--r-- | sysdeps/generic/pt-attr-getschedparam.c | 2 | ||||
-rw-r--r-- | sysdeps/generic/pt-attr-setschedparam.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sysdeps/generic/pt-attr-getschedparam.c b/sysdeps/generic/pt-attr-getschedparam.c index 25afebd0..6c3f15be 100644 --- a/sysdeps/generic/pt-attr-getschedparam.c +++ b/sysdeps/generic/pt-attr-getschedparam.c @@ -26,6 +26,6 @@ int pthread_attr_getschedparam (const pthread_attr_t *attr, struct sched_param *param) { - *param = attr->schedparam; + memcpy (param, &attr->schedparam, sizeof *param); return 0; } diff --git a/sysdeps/generic/pt-attr-setschedparam.c b/sysdeps/generic/pt-attr-setschedparam.c index 18a575ec..5459f108 100644 --- a/sysdeps/generic/pt-attr-setschedparam.c +++ b/sysdeps/generic/pt-attr-setschedparam.c @@ -30,7 +30,7 @@ pthread_attr_setschedparam (pthread_attr_t *attr, if (memcmp (param, &__pthread_default_attr.schedparam, sizeof *param) == 0) { - attr->schedparam = *param; + memcpy (&attr->schedparam, param, sizeof *param); return 0; } |