bug-gawk
[Top][All Lists]
Advanced

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

Re: gawk: sigpipe1.awk:7: fatal: print to "yes | true" failed: Broken pi


From: arnold
Subject: Re: gawk: sigpipe1.awk:7: fatal: print to "yes | true" failed: Broken pipe
Date: Sat, 13 Jan 2024 09:58:58 -0700
User-agent: Heirloom mailx 12.5 7/5/10

"Andrew J. Schorr" <aschorr@telemetry-investments.com> wrote:

> On Fri, Jan 12, 2024 at 03:02:49AM -0700, arnold@skeeve.com wrote:
> > I have just now pushed changes so that both gawk and gettimeofday()
> > use the same system call. clock_gettime() is preferred, then
> > gettimeofday(), and then time().
>
> Thanks!
>
> In extension/time.c, this patch looks weird though:
>
> +#if defined(HAVE_CLOCK_GETTIME)
> +       {
> +               struct timespec tv;
> +               clock_gettime(CLOCK_REALTIME, & tv);
> +               curtime = tv.tv_sec + 0.0;
> +               curtime = tv.tv_sec+(tv.tv_nsec/1000000000.0);
> +       }
> +#elif defined(HAVE_GETTIMEOFDAY)
>
> It seems that curtime is set twice; need to delete that first
> stray line?

Done. Thanks.

Arnold



reply via email to

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