From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: pgsql-hackers@lists.postgresql.org
Subject: Re: Why aren't we using strsignal(3) ?
Date: Sun, 16 Dec 2018 17:04:59 -0300
Message-ID: <20181216200459.yd6dmgaz4m57s6dv@alvherre.pgsql> (raw)
In-Reply-To: <25758.1544983503@sss.pgh.pa.us>
On 2018-Dec-16, Tom Lane wrote:
> I propose to replace all these places with code like
>
> snprintf(str, sizeof(str),
> _("child process was terminated by signal %d: %s"),
> WTERMSIG(exitstatus), pg_strsignal(WTERMSIG(exitstatus)));
>
> where pg_strsignal is a trivial wrapper around strsignal() if that
> exists, else it uses sys_siglist[] if that exists, else it just
> returns "unrecognized signal".
LGTM.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: alvherre@2ndquadrant.com, tgl@sss.pgh.pa.us, pgsql-hackers@lists.postgresql.org
Subject: Re: Why aren't we using strsignal(3) ?
In-Reply-To: <20181216200459.yd6dmgaz4m57s6dv@alvherre.pgsql>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox