After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 765466 - [PATCH] Not calling bindtextdomain causes error messages to become question marks on some locales
[PATCH] Not calling bindtextdomain causes error messages to become question m...
Status: RESOLVED FIXED
Product: glib
Classification: Platform
Component: network
2.48.x
Other FreeBSD
: Normal normal
: ---
Assigned To: gtkdev
gtkdev
Depends on:
Blocks:
 
 
Reported: 2016-04-23 14:25 UTC by Ting-Wei Lan
Modified: 2016-05-12 13:25 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
proxy, tls: Setup gettext in g_io_module_load(). (2.52 KB, patch)
2016-04-23 14:30 UTC, Ting-Wei Lan
committed Details | Review
proxy/gnome: Don't hardcode paths on Windows (2.98 KB, patch)
2016-05-12 08:33 UTC, Ignacio Casal Quinteiro (nacho)
none Details | Review
Don't hardcode paths on Windows (2.97 KB, patch)
2016-05-12 08:33 UTC, Ignacio Casal Quinteiro (nacho)
accepted-commit_now Details | Review

Description Ting-Wei Lan 2016-04-23 14:25:57 UTC
When running epiphany with zh_TW locale, connecting to https://www.ssllabs.com:10445/ shows the following message:
The precise error was: ?? TLS ???????:The Diffie-Hellman prime sent by the server is not acceptable (not long enough).

The correct message is:
The precise error was: 執行 TLS 交握時發生錯誤:The Diffie-Hellman prime sent by the server is not acceptable (not long enough).

Please see the attached patch. It fixes the problem by calling bindtextdomain and bind_textdomain_codeset in g_io_module_load.
Comment 1 Ting-Wei Lan 2016-04-23 14:30:23 UTC
Created attachment 326593 [details] [review]
proxy, tls: Setup gettext in g_io_module_load().

It is required to properly show error messages on some locales.
Comment 2 Dan Winship 2016-04-25 15:09:43 UTC
Thanks

Attachment 326593 [details] pushed as 2634fa5 - proxy, tls: Setup gettext in g_io_module_load().
Comment 3 Ignacio Casal Quinteiro (nacho) 2016-05-12 08:33:12 UTC
Created attachment 327678 [details] [review]
proxy/gnome: Don't hardcode paths on Windows

Use GLib'w Windows APIs to construct the path for the translations
dynamically on Windows.
Comment 4 Ignacio Casal Quinteiro (nacho) 2016-05-12 08:33:56 UTC
Created attachment 327680 [details] [review]
Don't hardcode paths on Windows

Use GLib'w Windows APIs to construct the path for the translations
dynamically on Windows.
Comment 5 Ignacio Casal Quinteiro (nacho) 2016-05-12 08:34:40 UTC
Reopening, please see the patch attached.
Comment 6 Dan Winship 2016-05-12 12:49:07 UTC
Comment on attachment 327680 [details] [review]
Don't hardcode paths on Windows

>Use GLib'w Windows APIs to construct the path for the translations

         ^^^ typo

other than that, the patch seems fine, but shouldn't there be a helper method for this in glib so we don't need the same boilerplate code everywhere?
Comment 7 Ignacio Casal Quinteiro (nacho) 2016-05-12 13:21:50 UTC
yeah... we could have some utility method shared among all modules but that would require all the modules to depend on something common. Apart from that there is really not something generic, see i.e that each project is also defined the global LOCALDIR_DIR variable.
Comment 8 Ignacio Casal Quinteiro (nacho) 2016-05-12 13:25:18 UTC
This problem has been fixed in the unstable development version. The fix will be available in the next major software release. You may need to upgrade your Linux distribution to obtain that newer version.