Thread: pgsql-server/src/backend/utils/adt pg_locale.c

pgsql-server/src/backend/utils/adt pg_locale.c

From
tgl@postgresql.org (Tom Lane)
Date:
CVSROOT:    /cvsroot
Module name:    pgsql-server
Changes by:    tgl@postgresql.org    02/10/18 16:44:02

Modified files:
    src/backend/utils/adt: pg_locale.c

Log message:
    Fix breakage that had crept into setlocale() usage: once again we've
    been bit by the fact that the locale functions return pointers to
    modifiable variables.  I added some comments that might help us avoid
    the mistake in future.


Re: pgsql-server/src/backend/utils/adt pg_locale.c

From
Bruce Momjian
Date:
This fixes our float() bug?

---------------------------------------------------------------------------

Tom Lane wrote:
> CVSROOT:    /cvsroot
> Module name:    pgsql-server
> Changes by:    tgl@postgresql.org    02/10/18 16:44:02
>
> Modified files:
>     src/backend/utils/adt: pg_locale.c
>
> Log message:
>     Fix breakage that had crept into setlocale() usage: once again we've
>     been bit by the fact that the locale functions return pointers to
>     modifiable variables.  I added some comments that might help us avoid
>     the mistake in future.
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org
>

--
  Bruce Momjian                        |  http://candle.pha.pa.us
  pgman@candle.pha.pa.us               |  (610) 359-1001
  +  If your life is a hard drive,     |  13 Roberts Road
  +  Christ can be your backup.        |  Newtown Square, Pennsylvania 19073

Re: pgsql-server/src/backend/utils/adt pg_locale.c

From
Tom Lane
Date:
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> This fixes our float() bug?

Teodor's complaint, yes.  (At least it fixes the HPUX manifestation,
but I imagine FreeBSD's problem is the same.)

            regards, tom lane