Skip to content

Commit

Permalink
Use C11 anonymous unions.
Browse files Browse the repository at this point in the history
PR:		215202
Reported by:	glebius

(cherry picked from commit a5ec4a9)
  • Loading branch information
lemul committed Mar 21, 2021
1 parent bf1863d commit 2b61bda
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions sys/sys/ucred.h
Expand Up @@ -89,12 +89,11 @@ struct xucred {
gid_t cr_groups[XU_NGROUPS]; /* groups */
union {
void *_cr_unused1; /* compatibility with old ucred */
pid_t _pid;
} _cr;
pid_t cr_pid;
};
};
#define XUCRED_VERSION 0

#define cr_pid _cr._pid
/* This can be used for both ucred and xucred structures. */
#define cr_gid cr_groups[0]

Expand Down

0 comments on commit 2b61bda

Please sign in to comment.