svn commit: r353640 - head/sys/kern

Peter Jeremy peter at rulingia.com
Wed Oct 23 18:45:16 UTC 2019


On 2019-Oct-16 13:21:02 +0000, Andrew Turner <andrew at FreeBSD.org> wrote:
>Author: andrew
>Date: Wed Oct 16 13:21:01 2019
>New Revision: 353640
>URL: https://svnweb.freebsd.org/changeset/base/353640
>
>Log:
>  Stop leaking information from the kernel through timespec
>  
>  The timespec struct holds a seconds value in a time_t and a nanoseconds
>  value in a long. On most architectures these are the same size, however
>  on 32-bit architectures other than i386 time_t is 8 bytes and long is
>  4 bytes.
>  
>  Most ABIs will then pad a struct holding an 8 byte and 4 byte value to
>  16 bytes with 4 bytes of padding. When copying one of these structs the
>  compiler is free to copy the padding if it wishes.

Are there any other structs passed from kernel to userland that include
padding?

-- 
Peter Jeremy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 963 bytes
Desc: not available
URL: <http://lists.freebsd.org/pipermail/svn-src-head/attachments/20191024/d7da560e/attachment.sig>


More information about the svn-src-head mailing list