Re: [PATCH] hstore: Fix parsing on Mac OS X: isspace() is locale specific

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [PATCH] hstore: Fix parsing on Mac OS X: isspace() is locale specific
Дата
Msg-id ZH8aia7JfdPjTKAY@paquier.xyz
обсуждение исходный текст
Ответ на [PATCH] hstore: Fix parsing on Mac OS X: isspace() is locale specific  (Evan Jones <evan.jones@datadoghq.com>)
Ответы Re: [PATCH] hstore: Fix parsing on Mac OS X: isspace() is locale specific
Список pgsql-hackers
On Mon, Jun 05, 2023 at 11:26:56AM -0400, Evan Jones wrote:
> This patch fixes a rare parsing bug with unicode characters on Mac OS X.
> The problem is that isspace() on Mac OS X changes its behaviour with the
> locale. Use scanner_isspace instead, which only returns true for ASCII
> whitespace. It appears other places in the Postgres code have already run
> into this, since a number of places use scanner_isspace instead. However,
> there are still a lot of other calls to isspace(). I'll try to take a quick
> look to see if there might be other instances of this bug.

Indeed.  It looks like 9ae2661 missed this spot.
--
Michael

Вложения

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

Предыдущее
От: Tomas Vondra
Дата:
Сообщение: Re: Do we want a hashset type?
Следующее
От: Alexander Lakhin
Дата:
Сообщение: Re: TRAP: FailedAssertion("prev_first_lsn < cur_txn->first_lsn", File: "reorderbuffer.c", Line: 927, PID: 568639)