]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
For the xenix_ftime() routine, don't use the native version of the struct --
authorsef <sef@FreeBSD.org>
Sun, 22 Jun 1997 19:04:03 +0000 (19:04 +0000)
committersef <sef@FreeBSD.org>
Sun, 22 Jun 1997 19:04:03 +0000 (19:04 +0000)
commit5bb5b9c674fc85cdb7a230aa57e80daed3afe82d
treecdbc8fad8f655ea080ee5df0f274bcc2943ea59d
parent472218ee7167476755c216566067072be6ba5b4a
For the xenix_ftime() routine, don't use the native version of the struct --
the XENIX version is packed, and two bytes smaller than ours.  So, define
the structure, and have it packed.  I used the __attribte__((packed))
modifier for this; I could also have surrounded the struct definition with
#pragma pack(2) -- but that would have meant making ibcs2_timeb's definition
outside the function.  This may need to be revisited if we ever want to
compile with a compiler other than gcc.  (I also used 'unsigned long'
instead of 'time_t' because I am writing to match an external specification
-- and the definition of time_t could change.)

Reviewed by: Steven Wallace
sys/i386/ibcs2/ibcs2_xenix.c