Re: [PATCH 2/2] libext2fs: use offsetof() from stddef.h

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Wed, Apr 14, 2021 at 12:41:28AM -0700, Michael Forney wrote:
> offsetof is a standard C feature available from stddef.h, going
> back all the way to ANSI C.
> 
> Signed-off-by: Michael Forney <mforney@xxxxxxxxxxx>

Thanks, applied.

> Perhaps there is some reason to prefer compiler builtins over libc
> that I'm not seeing?

It's because I pulled container_of from the kernel, and the kernel
header files has to provide offsetof since we don't use the standard
header files --- and it has to work across a bunch of compilers and
architectures.

						- Ted



[Index of Archives]     [Reiser Filesystem Development]     [Ceph FS]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Linux FS]     [Yosemite National Park]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Device Mapper]     [Linux Media]

  Powered by Linux