Re: Why aren't we using strsignal(3) ?

From: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: Re: Why aren't we using strsignal(3) ?
Date: 2018-12-16 20:04:59
Message-ID: 20181216200459.yd6dmgaz4m57s6dv@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2018-12-16 20:19:49 Re: reorderbuffer: memory overconsumption with medium-size subxacts
Previous Message David Rowley 2018-12-16 19:53:07 Re: Should new partitions inherit their tablespace from their parent?