From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fc89c,cd35c069ae659c58 X-Google-Attributes: gidfc89c,public X-Google-Thread: f678f,cd35c069ae659c58 X-Google-Attributes: gidf678f,public X-Google-Thread: fee84,cd35c069ae659c58 X-Google-Attributes: gidfee84,public X-Google-Thread: 1014db,cd35c069ae659c58 X-Google-Attributes: gid1014db,public From: karish@pangea.Stanford.EDU (Chuck Karish) Subject: Re: gmtime(): Doesn't account for leap seconds?! Date: 1996/04/24 Message-ID: <4lm50c$e3i@nntp.Stanford.EDU>#1/1 X-Deja-AN: 151245189 references: <4lid0q$itq@jik.israel.net> <830348597snz@genesis.demon.co.uk> <4lltpp$een@jik.israel.net> organization: Mindcraft, Inc. newsgroups: comp.unix.osf.misc,comp.unix.osf.osf1,comp.unix.programmer,comp.lang.c In article <4lltpp$een@jik.israel.net>, Jonathan Kamens wrote: >LINUX isn't "POSIX-complaint", per se, since only one Linux distribution >(Linux-FT) has been tested for compliance, and that distribution made numerous >changes to standard Linux software in order to obtain compliance. It's >entirely possible that they ripped out the leap second support in order to >pass the POSIX tests. Or that they didn't try to obtain full POSIX >compliance, and therefore weren't tested in this particular way. Or that the >POSIX tests missed this one :-). A version of Linux has been certified to conform to FIPS 151-2. It's not necessary to speculate about what might have been tested, because the source code of the NIST POSIX test suite tells the story. A system that corrects for leap seconds in gmtime() will definitely fail the NIST test. >Also, a Linux system without a file recording leap seconds *will* handle time >in a POSIX-compliant way, since if no leap seconds are defined, time will >behave as POSIX requires. It's just that if some goes ahead and adds leap >seconds to the configuration of the system, it will no longer be >POSIX-complaint. Therefore, it wouldn't surprise me at all if Linux-FT passed >the compliance tests simply by not configuring leap seconds, but leaving the >funcionality in so that their users can configure them in (and thereby "break" >POSIX compliance) if they desire. The right way to handle this is to provide a separate set of functions for use in those programs where leap seconds make a difference. -- Chuck Karish karish@mindcraft.com (415) 323-9000 x117 karish@pangea.stanford.edu