From ff892b7ce7155120a08759aeabce0b4cd24bc867 Mon Sep 17 00:00:00 2001 From: Robert Mustacchi Date: Tue, 2 Aug 2016 17:35:01 +0000 Subject: 7258 6951 caused uberdata32_t size to be incorrect Reviewed by: Dan McDonald Approved by: Gordon Ross --- usr/src/lib/libc/inc/thr_uberdata.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'usr/src/lib/libc') diff --git a/usr/src/lib/libc/inc/thr_uberdata.h b/usr/src/lib/libc/inc/thr_uberdata.h index 384a23582d..5adf2cfd51 100644 --- a/usr/src/lib/libc/inc/thr_uberdata.h +++ b/usr/src/lib/libc/inc/thr_uberdata.h @@ -905,15 +905,24 @@ typedef struct _qexthdlr { _quick_exithdlr_func_t hdlr; /* handler itself */ } _qexthdlr_t; +/* + * We add a pad on 32-bit systems to allow us to always have the structure size + * be 32-bytes which helps us deal with the compiler's alignment when building + * in ILP32 / LP64 systems. + */ typedef struct { mutex_t exitfns_lock; _qexthdlr_t *head; +#if !defined(_LP64) + uint32_t pad; +#endif } quickexit_root_t; #ifdef _SYSCALL32 typedef struct { mutex_t exitfns_lock; caddr32_t head; + uint32_t pad; } quickexit_root32_t; #endif /* _SYSCALL32 */ -- cgit v1.2.3