Re: C locale sort in src/tools/make_ctags - Mailing list pgsql-patches

From Bruce Momjian
Subject Re: C locale sort in src/tools/make_ctags
Date
Msg-id 200402021729.i12HTF705916@candle.pha.pa.us
Whole thread Raw
In response to Re: C locale sort in src/tools/make_ctags  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-patches
Tom Lane wrote:
> Peter Eisentraut <peter_e@gmx.net> writes:
> > Tom Lane wrote:
> >> I saw that, but it seemed a non-problem to me: if the variables have
> >> not been exported then they won't affect the sort program anyway.
>
> > He probably had LANG, but not LC_ALL, already exported in his
> > environment.
>
> Ah, right, that would explain it.
>
> > That's not possible, because LC_ALL overrides everything.
>
> I hadn't realized that, but you seem to be right.  Okay, setting
> LC_ALL correctly should be sufficient.

OK, new code is:

    LC_ALL=C
    export LC_ALL
    sort tags >/tmp/$$ && mv /tmp/$$ tags

--
  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

pgsql-patches by date:

Previous
From: Neil Conway
Date:
Subject: Re: reading uninitialized buffer
Next
From: Andrew Dunstan
Date:
Subject: Re: reading uninitialized buffer