Re: pgsql: Improve PQtrace() output format

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: David Rowley <dgrowleyml(at)gmail(dot)com>
Cc: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>, pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: Re: pgsql: Improve PQtrace() output format
Date: 2021-04-06 05:21:21
Message-ID: 948632.1617686481@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

I wrote:
> As best I can tell from these warnings, VS has the tv_sec field
> of struct timeval defined as something other than time_t. Because
> VS would never stoop to actually complying with the plain text of
> the POSIX standard.

Ah, seems like it's really Winsock's fault:

https://docs.microsoft.com/en-us/windows/win32/api/winsock/ns-winsock-timeval

which compares unfavorably to the POSIX wording

The <sys/time.h> header shall define the timeval structure, which
shall include at least the following members:

time_t tv_sec Seconds.
suseconds_t tv_usec Microseconds.

regards, tom lane

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2021-04-06 05:28:55 pgsql: Change return type of EXTRACT to numeric
Previous Message Fujii Masao 2021-04-06 05:10:25 pgsql: Fix typo in pgstat.c.