public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug locale/26383] New: bind_textdomain_codeset doesn't accept //TRANSLIT anymore
@ 2020-08-13 13:08 aurelien at aurel32 dot net
  2020-08-13 13:13 ` [Bug locale/26383] " aurelien at aurel32 dot net
                   ` (7 more replies)
  0 siblings, 8 replies; 9+ messages in thread
From: aurelien at aurel32 dot net @ 2020-08-13 13:08 UTC (permalink / raw)
  To: glibc-bugs

https://sourceware.org/bugzilla/show_bug.cgi?id=26383

            Bug ID: 26383
           Summary: bind_textdomain_codeset doesn't accept //TRANSLIT
                    anymore
           Product: glibc
           Version: 2.32
            Status: NEW
          Severity: normal
          Priority: P2
         Component: locale
          Assignee: unassigned at sourceware dot org
          Reporter: aurelien at aurel32 dot net
                CC: arjun.is at lostca dot se
  Target Milestone: ---

bind_textdomain_codeset used to accept a charset ending with //TRANSLIT, as
described in the documentation:
"The bind_textdomain_codeset function can be used to specify the output
character set for message catalogs for domain domainname. The codeset argument
must be a valid codeset name which can be used for the iconv_open function, or
a null pointer."

However this is not the case anymore in glibc 2.32, and more precisely since
commit 91927b7c76437db860cd86a7714476b56bb39d07. This can be seen with the
following testcase:

#include <libintl.h>
#include <locale.h>
#include <stdio.h>

void main()
{
        setlocale(LC_ALL, "fr_FR.UTF-8");

        bind_textdomain_codeset("libc", "utf-8//TRANSLIT");
        printf("translation of NAME into French: %s\n", dgettext("libc",
"NAME"));
}

With glibc 2.31, it prints:
translation of NAME into French: NOM

With glibc 2.32, it prints:
translation of NAME into French: NAME

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2020-10-20 15:55 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-13 13:08 [Bug locale/26383] New: bind_textdomain_codeset doesn't accept //TRANSLIT anymore aurelien at aurel32 dot net
2020-08-13 13:13 ` [Bug locale/26383] " aurelien at aurel32 dot net
2020-08-13 20:17 ` vincent-srcware at vinc17 dot net
2020-08-25 10:01 ` arjun.is at lostca dot se
2020-08-25 10:01 ` arjun.is at lostca dot se
2020-08-25 19:45 ` carlos at redhat dot com
2020-09-25 12:49 ` arjun.is at lostca dot se
2020-10-15 11:31 ` arjun.is at lostca dot se
2020-10-20 15:55 ` arjun.is at lostca dot se

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).