Re: Unhelpful error message




On Oct 4, 2013, at 8:55 PM, John Ralls <jralls ceridwen us> wrote:


On Oct 4, 2013, at 7:52 PM, "Ronald F. Guilmette" <rfg tristatelogic com> wrote:



I get the following message often, usually (apparently) as a by-product
of running some browser (e.g. Firefox) or another (e.g. Opera):

  (process:22681): Gtk-WARNING **: Locale not supported by C library.
          Using the fallback 'C' locale.

I googled it and quite obviously I am far from alone in being frequently
annoyed by this message.

Would the authors/maintainers of GTK mind very much improving the message,
you know, so that it would at least give the user the *name* of the specific
offending locale that GTK is actually complaining about?  I mean is that
too much to ask?

I do believe that that one key piece of missing information would be
rather helpful to those thousands of people, including me, who are
trying to understand the genesis of this error and also how to suppress
it.
______________________________________________

The code in question (at gtk/gtkmain.c:622),
     if (!setlocale (LC_ALL, ""))
       g_warning ("Locale not supported by C library.\n\tUsing the fallback 'C' locale.");
can't see which locale isn't supported. It's set in one or more of the locale environment variables
(see locale(1)), and is generally the OS's fault rather than Gtk's: The problem isn't that translations
for gtk aren't available (that would be a gettext call), it's that the locale isn't enabled at the OS level.
The failure is occurring on every localized application which you run; it's just the Gtk ones which
are courteous enough to let you know.

To see what locales are set in your environment, from a shell prompt say:
 env | egrep "(LC|LANG)"
Then check every locale according to how your distro enables them.

Regards,
John Ralls



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]