diff options
author | Paul Eggert <eggert@cs.ucla.edu> | 2023-07-19 14:09:26 -0700 |
---|---|---|
committer | Arjun Shankar <arjun@redhat.com> | 2024-03-18 11:45:19 +0100 |
commit | e24f8e6b35ee0242312cb0f1a9fb5a76403e724e (patch) | |
tree | 365b68dd84a4726ee1e7759ffd3ee0bd5f39ef45 | |
parent | 4d4ba8bae4bac5e0fd266c22517a3f16a1006bbe (diff) | |
download | glibc-e24f8e6b35ee0242312cb0f1a9fb5a76403e724e.tar.gz glibc-e24f8e6b35ee0242312cb0f1a9fb5a76403e724e.tar.xz glibc-e24f8e6b35ee0242312cb0f1a9fb5a76403e724e.zip |
make ‘struct pthread’ a complete type
* nptl/descr.h (struct pthread): Remove end_padding member, which made this type incomplete. (PTHREAD_STRUCT_END_PADDING): Stop using end_padding. Reviewed-by: Siddhesh Poyarekar <siddhesh@sourceware.org> (cherry picked from commit 3edc4ff2ceff4a59587ebecb94148d3bcfa1df62)
-rw-r--r-- | nptl/descr.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/nptl/descr.h b/nptl/descr.h index 5cacb286f3..70cf4b639a 100644 --- a/nptl/descr.h +++ b/nptl/descr.h @@ -405,11 +405,11 @@ struct pthread /* rseq area registered with the kernel. */ struct rseq rseq_area; - /* This member must be last. */ - char end_padding[]; - + /* Amount of end padding, if any, in this structure. + This definition relies on rseq_area being last. */ #define PTHREAD_STRUCT_END_PADDING \ - (sizeof (struct pthread) - offsetof (struct pthread, end_padding)) + (sizeof (struct pthread) - offsetof (struct pthread, rseq_area) \ + + sizeof (struct rseq)) } __attribute ((aligned (TCB_ALIGNMENT))); static inline bool |