Re: ksh: count $SECONDS with monotonic clock

2018-04-13 Thread Todd C. Miller
On Fri, 13 Apr 2018 19:42:51 +0200, Jeremie Courreges-Anglas wrote: > The diff uses timespecsub: Ah, OK. That's fine then. - todd

Re: ksh: count $SECONDS with monotonic clock

2018-04-13 Thread Jeremie Courreges-Anglas
On Fri, Apr 13 2018, "Todd C. Miller" wrote: > On Fri, 13 Apr 2018 11:11:04 -0500, Scott Cheloha wrote: > >> So that $SECONDS advances uniformly, independent of the system clock. > > Why are you including sys/time.h? For struct timespect you only > need time.h which is already included. > > In ge

Re: ksh: count $SECONDS with monotonic clock

2018-04-13 Thread Todd C. Miller
On Fri, 13 Apr 2018 11:11:04 -0500, Scott Cheloha wrote: > So that $SECONDS advances uniformly, independent of the system clock. Why are you including sys/time.h? For struct timespect you only need time.h which is already included. In general, you only need sys/time.h for struct timeval or for

Re: ksh: count $SECONDS with monotonic clock

2018-04-13 Thread Jeremie Courreges-Anglas
On Fri, Apr 13 2018, Scott Cheloha wrote: > So that $SECONDS advances uniformly, independent of the system clock. > > ok? ok jca@ > -- > Scott Cheloha > > P.S. Similar change forthcoming for $MAILCHECK. > > Index: bin/ksh/var.c > ==