Page Menu
Home
FreeBSD
Search
Configure Global Search
Log In
Files
F107319836
D46916.id.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Size
1 KB
Referenced Files
None
Subscribers
None
D46916.id.diff
View Options
diff --git a/sys/kern/kern_prot.c b/sys/kern/kern_prot.c
--- a/sys/kern/kern_prot.c
+++ b/sys/kern/kern_prot.c
@@ -2181,11 +2181,6 @@
bcopy(&src->cr_startcopy, &dest->cr_startcopy,
(unsigned)((caddr_t)&src->cr_endcopy -
(caddr_t)&src->cr_startcopy));
- /*
- * Avoid an assertion in crsetgroups() -> crextend(). To be removed as
- * 'cr_ngroups' is moved out of the bcopied area.
- */
- dest->cr_ngroups = 0;
dest->cr_flags = src->cr_flags;
crsetgroups(dest, src->cr_ngroups, src->cr_groups);
uihold(dest->cr_uidinfo);
diff --git a/sys/sys/ucred.h b/sys/sys/ucred.h
--- a/sys/sys/ucred.h
+++ b/sys/sys/ucred.h
@@ -72,20 +72,22 @@
u_int cr_users; /* (c) proc + thread using this cred */
u_int cr_flags; /* credential flags */
struct auditinfo_addr cr_audit; /* Audit properties. */
-#define cr_startcopy cr_uid
+#define cr_startcopy cr_ispare
+ u_int cr_ispare; /* spare integer */
+ gid_t cr_rgid; /* real group id */
+ gid_t cr_svgid; /* saved group id */
uid_t cr_uid; /* effective user id */
uid_t cr_ruid; /* real user id */
uid_t cr_svuid; /* saved user id */
- int cr_ngroups; /* number of groups */
- gid_t cr_rgid; /* real group id */
- gid_t cr_svgid; /* saved group id */
struct uidinfo *cr_uidinfo; /* per euid resource consumption */
struct uidinfo *cr_ruidinfo; /* per ruid resource consumption */
struct prison *cr_prison; /* jail(2) */
struct loginclass *cr_loginclass; /* login class */
- void *cr_pspare2[2]; /* general use 2 */
+ void *cr_pspare[1]; /* spare pointer */
#define cr_endcopy cr_label
struct label *cr_label; /* MAC label */
+ u_int cr_ispare2; /* spare integer */
+ int cr_ngroups; /* number of groups */
gid_t *cr_groups; /* groups */
int cr_agroups; /* Available groups */
/* storage for small groups */
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Mon, Jan 13, 10:40 AM (19 h, 16 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
15780969
Default Alt Text
D46916.id.diff (1 KB)
Attached To
Mode
D46916: cred: 'struct ucred': Move 'cr_ngroups' out of the bcopied area
Attached
Detach File
Event Timeline
Log In to Comment