Hide Forgot
+++ This bug was initially created as a clone of Bug #1322292 +++ Description of problem: While testing ausearch time parsing we recently discovered that some locales have broken date and time. In particular, a time given by strftime() cannot be parsed correctly by strptime() afterwards. In RHEL-6.8 Snapshot 2.0 there are 50 such locales, the list of them is attached to this BZ. A test case for glibc prepared by Steve Grubb is attached to this BZ as well. Version-Release number of selected component (if applicable): glibc-2.12-1.192.el6 How reproducible: 100% Steps to Reproduce: 1. Compile the test case into test binary. 2. execute it for each locale (for L in $(locale -a); do ./test $L; done) Actual results: 50 broken locales, from ar_AE to my_MM.utf8. Expected results: No broken locales. Additional info: I would like to thank Steve to pointing to the issue and sharing the test case. --- Additional comment from Ondrej Moriš on 2016-03-30 04:38 EDT --- --- Additional comment from Ondrej Moriš on 2016-03-30 04:39 EDT --- --- Additional comment from Carlos O'Donell on 2016-03-30 15:45:58 EDT --- Upstream 2.22 has less broken locales: Error converting time string to struct in gd_GB locale Error converting time string to struct in gd_GB.iso885915 locale Error converting time string to struct in gd_GB.utf8 locale Error converting time string to struct in lzh_TW locale Error converting time string to struct in lzh_TW.utf8 locale Error converting time string to struct in my_MM locale Error converting time string to struct in my_MM.utf8 locale Same with upstream master (using a chroot script): FAIL: Error converting time string to struct in gd_GB locale FAIL: Error converting time string to struct in gd_GB.iso885915 locale FAIL: Error converting time string to struct in gd_GB.utf8 locale FAIL: Error converting time string to struct in lzh_TW locale FAIL: Error converting time string to struct in lzh_TW.utf8 locale FAIL: Error converting time string to struct in my_MM locale FAIL: Error converting time string to struct in my_MM.utf8 locale This is going to have to go upstream first. Depending on the change the backport may not be suitable for RHEL6, but might be for RHEL7 (I'll clone to there next). I filed an upstream bug. https://sourceware.org/bugzilla/show_bug.cgi?id=19890 --- Additional comment from Carlos O'Donell on 2016-03-30 15:50:32 EDT --- RHEL 7 shows: FAIL: Error converting time string to struct in ar_AE locale FAIL: Error converting time string to struct in ar_AE.iso88596 locale FAIL: Error converting time string to struct in ar_AE.utf8 locale FAIL: Error converting time string to struct in ar_BH locale FAIL: Error converting time string to struct in ar_BH.iso88596 locale FAIL: Error converting time string to struct in ar_BH.utf8 locale FAIL: Error converting time string to struct in ar_DZ locale FAIL: Error converting time string to struct in ar_DZ.iso88596 locale FAIL: Error converting time string to struct in ar_DZ.utf8 locale FAIL: Error converting time string to struct in ar_EG locale FAIL: Error converting time string to struct in ar_EG.iso88596 locale FAIL: Error converting time string to struct in ar_EG.utf8 locale FAIL: Error converting time string to struct in ar_IQ locale FAIL: Error converting time string to struct in ar_IQ.iso88596 locale FAIL: Error converting time string to struct in ar_IQ.utf8 locale FAIL: Error converting time string to struct in ar_JO locale FAIL: Error converting time string to struct in ar_JO.iso88596 locale FAIL: Error converting time string to struct in ar_JO.utf8 locale FAIL: Error converting time string to struct in ar_KW locale FAIL: Error converting time string to struct in ar_KW.iso88596 locale FAIL: Error converting time string to struct in ar_KW.utf8 locale FAIL: Error converting time string to struct in ar_LB locale FAIL: Error converting time string to struct in ar_LB.iso88596 locale FAIL: Error converting time string to struct in ar_LB.utf8 locale FAIL: Error converting time string to struct in ar_LY locale FAIL: Error converting time string to struct in ar_LY.iso88596 locale FAIL: Error converting time string to struct in ar_LY.utf8 locale FAIL: Error converting time string to struct in ar_MA locale FAIL: Error converting time string to struct in ar_MA.iso88596 locale FAIL: Error converting time string to struct in ar_MA.utf8 locale FAIL: Error converting time string to struct in ar_OM locale FAIL: Error converting time string to struct in ar_OM.iso88596 locale FAIL: Error converting time string to struct in ar_OM.utf8 locale FAIL: Error converting time string to struct in ar_QA locale FAIL: Error converting time string to struct in ar_QA.iso88596 locale FAIL: Error converting time string to struct in ar_QA.utf8 locale FAIL: Error converting time string to struct in ar_SD locale FAIL: Error converting time string to struct in ar_SD.iso88596 locale FAIL: Error converting time string to struct in ar_SD.utf8 locale FAIL: Error converting time string to struct in ar_SY locale FAIL: Error converting time string to struct in ar_SY.iso88596 locale FAIL: Error converting time string to struct in ar_SY.utf8 locale FAIL: Error converting time string to struct in ar_TN locale FAIL: Error converting time string to struct in ar_TN.iso88596 locale FAIL: Error converting time string to struct in ar_TN.utf8 locale FAIL: Error converting time string to struct in ar_YE locale FAIL: Error converting time string to struct in ar_YE.iso88596 locale FAIL: Error converting time string to struct in ar_YE.utf8 locale FAIL: Error converting time string to struct in my_MM locale FAIL: Error converting time string to struct in my_MM.utf8 locale FAIL: Error setting locale no_NO.ISO-8859-1 Which points at a core ar_* locale issue, and a core my_* locale issue.
There is currently no fix for this and there haven't been many requests to fix this issue (beyond developer thoroughness in testing). I'm marking this CLOSED/WONTFIX. We will track this via the upstream bug report, and work there to improve testing and fix the issues with the locales (which are a smaller set in glibc master).