From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Achim Gratz Newsgroups: gmane.emacs.bugs Subject: bug#12392: emacs-gtk misinterprets floating-point numbers under certain locales on openSUSE 12.2 Date: Sat, 22 Sep 2012 18:36:30 +0200 Organization: Linux Private Site Message-ID: <87ehluf20h.fsf@Rainer.invalid> References: <87r4qbodec.fsf@Rainer.invalid> <87zk4ifukb.fsf@Rainer.invalid> <1544800.869GeMQOQf@thinkpad.home> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1348331850 18107 80.91.229.3 (22 Sep 2012 16:37:30 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 22 Sep 2012 16:37:30 +0000 (UTC) To: 12392@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sat Sep 22 18:37:33 2012 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1TFSht-00063M-3n for geb-bug-gnu-emacs@m.gmane.org; Sat, 22 Sep 2012 18:37:29 +0200 Original-Received: from localhost ([::1]:50738 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFSho-00075o-IT for geb-bug-gnu-emacs@m.gmane.org; Sat, 22 Sep 2012 12:37:24 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:48420) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFShl-00075T-5S for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:37:22 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TFShj-0005HJ-Nf for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:37:21 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:39837) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFShj-0005HF-KR for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:37:19 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.72) (envelope-from ) id 1TFSjO-0000jD-MU for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:39:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <87r4qbodec.fsf@Rainer.invalid> Resent-From: Achim Gratz Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 22 Sep 2012 16:39:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 12392 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.13483319172678 (code B ref -1); Sat, 22 Sep 2012 16:39:02 +0000 Original-Received: (at submit) by debbugs.gnu.org; 22 Sep 2012 16:38:37 +0000 Original-Received: from localhost ([127.0.0.1]:49383 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TFSiz-0000h9-EE for submit@debbugs.gnu.org; Sat, 22 Sep 2012 12:38:37 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:46492) by debbugs.gnu.org with esmtp (Exim 4.72) (envelope-from ) id 1TFSix-0000h2-NQ for submit@debbugs.gnu.org; Sat, 22 Sep 2012 12:38:37 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TFShG-0005F0-VK for submit@debbugs.gnu.org; Sat, 22 Sep 2012 12:36:52 -0400 Original-Received: from lists.gnu.org ([208.118.235.17]:60313) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFShG-0005Ek-SH for submit@debbugs.gnu.org; Sat, 22 Sep 2012 12:36:50 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:48336) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFShF-000755-NU for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:36:50 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1TFShE-0005Dz-7Q for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:36:49 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:45652) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1TFShE-0005Dv-0M for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 12:36:48 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1TFShD-0005TI-1Y for bug-gnu-emacs@gnu.org; Sat, 22 Sep 2012 18:36:47 +0200 Original-Received: from pd9eb57bc.dip.t-dialin.net ([217.235.87.188]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 22 Sep 2012 18:36:47 +0200 Original-Received: from Stromeko by pd9eb57bc.dip.t-dialin.net with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Sat, 22 Sep 2012 18:36:47 +0200 X-Injected-Via-Gmane: http://gmane.org/ Original-Lines: 48 Original-X-Complaints-To: usenet@ger.gmane.org X-Gmane-NNTP-Posting-Host: pd9eb57bc.dip.t-dialin.net User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux) Cancel-Lock: sha1:TCWBN5IOsQekCFmwIBgUYPF4FX0= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.13 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 140.186.70.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:64755 Archived-At: Holger Arnold writes: > May I cite: "Note, however, that changing the locale after GTK+ is initialized > may produce inconsistent results and is not really supported." This warning > is not related to this particular function, as gtk_set_locale() does nothing > more than calling setlocale(LC_ALL, ""). Emacs calls this function via > gtk_init(). That part is documented and it can be suppressed via gtk_disable_setlocale() at the discretion of the application. The warning about inconsistent results is about locale-dependent things set up in gtk_init() that would need to be re-run if the locale changes. > Note that _any_ program having a localized user interface has to call > setlocale(LC_ALL, "") at the start to set the locale to the value specified by > its environment. gtk_init() simply does this for you. If you don't like that > behavior, you can initialize GTK without calling gtk_init() (but this wouldn't > help with GStreamer). Yes and that's a bug right there in GStreamer. If the locale environment is already set up, it has no business in querying the initial environment again. > As to whether calling setlocale(LC_ALL, "") in a library is a bug, what would > you expect a library that wants to provide localized messages to do? Changing > the locale before and after each call? This would be racy in a multi-threaded > program. An application may chose to never set up a locale and there should be a way to tell libraries to respect that (I don't think there is a foolproof way to check for whether a locale has already been set up by the application). Gtk has that, but GStreamer is missing or ignoring it. Plus it must be a development that happened in a version between 12.1 and 12.2. Here's another one with the same or very similar problem: https://github.com/pavouk/lgi/issues/19 I don't know where the "gstreamer override file" can be found that he talks about. :-( Regards, Achim. -- +<[Q+ Matrix-12 WAVE#46+305 Neuron microQkb Andromeda XTk Blofeld]>+ Factory and User Sound Singles for Waldorf rackAttack: http://Synth.Stromeko.net/Downloads.html#WaldorfSounds