This is the mail archive of the
glibc-bugs@sourceware.org
mailing list for the glibc project.
[Bug libc/11333] size of struct dirent does not agree with kernel when using LFS on 32bit
- From: "kees at outflux dot net" <sourceware-bugzilla at sourceware dot org>
- To: glibc-bugs at sources dot redhat dot com
- Date: 27 Feb 2010 07:16:40 -0000
- Subject: [Bug libc/11333] size of struct dirent does not agree with kernel when using LFS on 32bit
- References: <20100227055549.11333.kees@outflux.net>
- Reply-to: sourceware-bugzilla at sourceware dot org
------- Additional Comments From kees at outflux dot net 2010-02-27 07:16 -------
Looks like the kernel unconditionally aligns/pads to 8 bytes in the 64bit
interface. fs/readdir.c, filldir64() says:
int reclen = ALIGN(NAME_OFFSET(dirent) + namlen + 1, sizeof(u64));
which means it looks like alignment needs to be forced in glibc too. I don't
think __attribute__ ((aligned (sizeof (__off64_t)))) is acceptable for
bits/dirent.h as that's a gcc extension. Thoughts?
--
http://sourceware.org/bugzilla/show_bug.cgi?id=11333
------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.