[Top][All Lists]

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

Re: POSIX defines struct timeval in <sys/types.h>

From: Chet Ramey
Subject: Re: POSIX defines struct timeval in <sys/types.h>
Date: Wed, 8 Sep 2021 09:36:48 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:78.0) Gecko/20100101 Thunderbird/78.13.0

On 9/5/21 10:57 AM, Ori Sky Farrell wrote:
> I've discovered a gap in POSIX compliance in lib/sh/strftime.c on the devel 
> branch. POSIX mandates that the timeval struct be defined in <sys/time.h>, 
> although as can be seen on Line 67 of the file in question, the file is only 
> included here if the tm struct -- which POSIX mandates be defined in <time.h> 
> -- is defined in <sys/time.h>.

It's interesting that your libc implementation claims POSIX conformity with
respect to this:

> The libc implementation I'm working with defines timeval in <sys/time.h> and 
> tm in <time.h> as mandated by POSIX so here I encounter a compile failure on 
> Line 193.

and yet does not include the POSIX-required strftime().

I'll look at the <sys/time.h> and <time.h> issues.

``The lyf so short, the craft so long to lerne.'' - Chaucer
                 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

reply via email to

[Prev in Thread] Current Thread [Next in Thread]