Re: Collation patch's handling of wcstombs/mbstowcs is sheerest fantasy
В списке pgsql-hackers по дате отправления:
| От | Peter Eisentraut |
|---|---|
| Тема | Re: Collation patch's handling of wcstombs/mbstowcs is sheerest fantasy |
| Дата | |
| Msg-id | 1303689455.5006.18.camel@vanquo.pezone.net обсуждение исходный текст |
| Ответ на | Re: Collation patch's handling of wcstombs/mbstowcs is sheerest fantasy (Tom Lane <tgl@sss.pgh.pa.us>) |
| Список | pgsql-hackers |
On lör, 2011-04-23 at 11:37 -0400, Tom Lane wrote: > I wrote: > > * Where they're not, install the locale_t with uselocale(), do > > mbstowcs or wcstombs, and revert to the former locale_t setting. > > This is ugly as sin, and not thread-safe, but of course lots of > > the backend is not thread-safe. > > I've been corrected on that: uselocale() *is* thread safe, at least in > glibc (it only affects the locale used by the current thread). And it's > "only a few instructions" according to Jakub Jelinek. So a temporary > setting via uselocale is exactly what you're supposed to do for any > locale-sensitive function that hasn't got a *_l variant. Good to know. It was certainly very strange, this gap in the API.
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера