lkml.org 
[lkml]   [2023]   [Aug]   [1]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
SubjectRe: [PATCH v2] x86: Fix x32 System V message queue syscalls
From
On 01/08/2023 08:15, Florian Weimer wrote:
> * Harald van Dijk:
>
>> There is one complication that I think has not been mentioned yet:
>> when _GNU_SOURCE is defined, glibc does provide a definition of struct
>> msghdr in <sys/msg.h> with a field "__syscall_slong_t mtype;". This
>> makes it slightly more likely that there is code out there in the wild
>> that works fine with current kernels and would be broken by the
>> fix. Given how rare x32 is, and how rare message queues are, this may
>> still be acceptable, but I am mentioning it just in case this would
>> cause a different approach to be preferred. And whatever is done, a
>> fix should also be submitted to glibc.
>
> What should glibc do here? Just change the definition in the header to
> long and ignore the breakage?

Yes, I believe so, but perhaps for glibc it might make sense to wait a
little bit to see if it does indeed go into the kernel in that form. If
the kernel ends up preferring something else, the change needed in glibc
might also be different.

Cheers,
Harald van Dijk

\
 
 \ /
  Last update: 2023-08-01 14:16    [W:0.103 / U:0.460 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site