From 9f7bf94ee2a88a702cef9fdb67166404c275afaf Mon Sep 17 00:00:00 2001 From: Alex S Date: Wed, 9 Nov 2022 00:17:17 +0300 Subject: [PATCH] linux(4): Fix get_robust_list() syscall return value. The system call returns the head of the robust futex list. The list head is stored in the location pointed to by the head argument. When copying data between address spaces use proper head storage size as it depends on an emulated ABI. PR: 267616 MFC after: 3 days --- sys/compat/linux/linux_futex.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sys/compat/linux/linux_futex.c b/sys/compat/linux/linux_futex.c index eb3ce342146..d16e047f831 100644 --- a/sys/compat/linux/linux_futex.c +++ b/sys/compat/linux/linux_futex.c @@ -931,7 +931,7 @@ linux_get_robust_list(struct thread *td, struct linux_get_robust_list_args *args if (error != 0) return (EFAULT); - return (copyout(&head, args->head, sizeof(head))); + return (copyout(&head, args->head, sizeof(l_uintptr_t))); } static int