On Wed, 9 Sep 2026 13:21:24 GMT, Matthias Baesken <[email protected]> wrote:
>> We build with std=c11 so it should be fine to move the declaration. >> And there are already code locations in the C codebase where this is done >> https://github.com/openjdk/jdk/blob/master/src/java.base/macosx/native/libnio/ch/FileDispatcherImpl.c#L54 > > Looking at it more, we need the `struct group_source_req req;` declaration > twice, once for the 'non-Apple' code at lines 710ff. And also for the > AIX-only code a few lines before the end of the function. > So I would prefer keeping the code as it is, because declaring it twice is > not really nicer than having the non-APPLE macro check. Good point, I hadn't noticed its usage in the AIX section. Leaving it in the current proposed form seems OK to me. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/32782#discussion_r3968963583
