Page MenuHomeFreeBSD

linux: getsockopt(): Simplify exporting groups a bit
ClosedPublic

Authored by olce on Aug 29 2025, 11:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Nov 11, 3:46 AM
Unknown Object (File)
Thu, Nov 6, 12:09 AM
Unknown Object (File)
Mon, Oct 27, 11:27 AM
Unknown Object (File)
Oct 13 2025, 8:43 AM
Unknown Object (File)
Oct 12 2025, 8:21 PM
Unknown Object (File)
Oct 12 2025, 8:21 PM
Unknown Object (File)
Oct 12 2025, 8:45 AM
Unknown Object (File)
Oct 4 2025, 6:56 PM
Subscribers

Details

Summary

No functional change (intended).

Go through conversion to a 'l_gid_t' before copying out in order to cope
with differing group types (except for not representable values, of
course). This is what is done, e.g., for getgroups() in 'linux_misc.c'.
As Linux's group type is the same as ours on all architectures, we could
as well just stop bothering and copy out our memory representation,
eliminating the loop here. Whatever the choice, though, it has to be
consistent here and there.

Introduce 'out' of type 'l_gid_t' to avoid performing "by hand" array
arithmetics when copying out.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Skipped
Unit
Tests Skipped
Build Status
Buildable 66683
Build 63566: arc lint + arc unit