Re: Thread-unsafe coding in ecpg - Mailing list pgsql-hackers

From Michael Meskes
Subject Re: Thread-unsafe coding in ecpg
Date
Msg-id d441f5913b147e5b3e0eed4647f9839d926d90fc.camel@postgresql.org
Whole thread Raw
In response to Re: Thread-unsafe coding in ecpg  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Thread-unsafe coding in ecpg  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
> > The question is, what do we do on those platforms? Use setlocale()
> > or
> > fallback to (a) and document that ecpg has to run in a C locale?
> 
> No, we shouldn't use setlocale(), because it clearly is hazardous
> even on platforms where it doesn't fail outright.  I don't see
> anything so wrong with just documenting the hazard.  The situation

Actually I meant using setlocale() and documenting that it must not be
used with threads, or document it must not be used with locales?

Michael
-- 
Michael Meskes
Michael at Fam-Meskes dot De, Michael at Meskes dot (De|Com|Net|Org)
Meskes at (Debian|Postgresql) dot Org
Jabber: michael at xmpp dot meskes dot org
VfL Borussia! Força Barça! SF 49ers! Use Debian GNU/Linux, PostgreSQL



pgsql-hackers by date:

Previous
From: Pavel Stehule
Date:
Subject: Re: PostgreSQL vs SQL/XML Standards
Next
From: Tomas Vondra
Date:
Subject: Re: shared-memory based stats collector