Re: Allowing printf("%m") only where it actually works

Поиск
Список
Период
Сортировка
От Nico Williams
Тема Re: Allowing printf("%m") only where it actually works
Дата
Msg-id 20180819045050.GB16780@localhost
обсуждение исходный текст
Ответ на Re: Allowing printf("%m") only where it actually works  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Allowing printf("%m") only where it actually works
Список pgsql-hackers
On Sat, Aug 18, 2018 at 04:34:50PM -0400, Tom Lane wrote:
> So now I'm about ready to propose that we just *always* use
> snprintf.c, and forget all of the related configure probing.

Yes.

> This'd have some advantages, notably that we'd get the
> useful_strerror() behavior in frontend as well as backend,
> assuming we converted all our frontend code to use %m.

You'd also get to ensure that all uses from *die() are
async-signal-safe.

You'd also ensure that snprintf.c gets maximal testing.

> And we'd not exactly be the first project to decide that.
> But it's kind of a big move from where we are today.
> 
> Thoughts?

I think that is the best approach.


В списке pgsql-hackers по дате отправления:

Предыдущее
От: Masayuki Takahashi
Дата:
Сообщение: Re: How to estimate the shared memory size required for parallel scan?
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Allowing printf("%m") only where it actually works