Re: [bug] Wrong bool value parameter

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [bug] Wrong bool value parameter
Дата
Msg-id 27959.1586618713@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: [bug] Wrong bool value parameter  (wenjing <wjzeng2012@gmail.com>)
Список pgsql-bugs
wenjing <wjzeng2012@gmail.com> writes:
> 2020年4月7日 22:35,Masahiko Sawada <masahiko.sawada@2ndquadrant.com> 写道:
>>> I'm not sure it is a bug. It certainly can be an improvement. Code as is does not cause issues although I concur
withyou that it is at least a strange syntax. It is like this at least since 2009 (commit ba748f7a11e). I'm not sure
parse_bool*is the right place to fix it because it could break code. IMHO the problem is that parse_one_reloption() is
usingthe value provided by user; it should test those (abbreviation) conditions and store "true" (for example) as bool
value.

> It seems difficult to store a new bool value in parse_one_reloption. This is a string stored with ”autovacuum_enabled
=“.
> any other ideas?

I don't think we should touch this.  If the user chose to write the value
in a specific way, they might've had a reason for that.  There's little
reason for us to override it, certainly not enough to justify introducing
a lot of new mechanism just to do that.

            regards, tom lane



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

Предыдущее
От: wenjing
Дата:
Сообщение: Re: [bug] Wrong bool value parameter
Следующее
От: Tomas Vondra
Дата:
Сообщение: Re: BUG #16112: large, unexpected memory consumption