Re: A new function to wait for the backend exit after termination

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Hou, Zhijie" <houzj(dot)fnst(at)cn(dot)fujitsu(dot)com>
Cc: Bharath Rupireddy <bharath(dot)rupireddyforpostgres(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Muhammad Usama <m(dot)usama(at)gmail(dot)com>
Subject: Re: A new function to wait for the backend exit after termination
Date: 2020-12-03 02:01:34
Message-ID: 1686547.1606960894@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

"Hou, Zhijie" <houzj(dot)fnst(at)cn(dot)fujitsu(dot)com> writes:
> + ereport(WARNING,
> + (errmsg("could not wait for the termination of the backend with PID %d within %ld milliseconds",
> + pid, timeout)));

> The code use %ld to print int64 type.
> How about use INT64_FORMAT, which looks more appropriate.

This is a translatable message, so INT64_FORMAT is no good -- we need
something that is the same across platforms. The current project standard
for this problem is to use "%lld" and explicitly cast the argument to long
long int to match that.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Michael Paquier 2020-12-03 02:03:49 Renaming cryptohashes.c to cryptohashfuncs.c
Previous Message Hou, Zhijie 2020-12-03 01:54:33 RE: A new function to wait for the backend exit after termination