]> git.ipfire.org Git - thirdparty/gettext.git/commitdiff
Fix for HP-UX, where the strftime() result is actually "f\xE9vr".
authorBruno Haible <bruno@clisp.org>
Thu, 19 Jun 2003 16:13:12 +0000 (16:13 +0000)
committerBruno Haible <bruno@clisp.org>
Tue, 23 Jun 2009 10:10:43 +0000 (12:10 +0200)
gettext-tools/m4/locale-fr.m4

index 5721733a5b42179b730bf1343c4ed0990af8df7a..7788af9468ba85a44e301bcdbf6d58d0f6bca572 100644 (file)
@@ -21,10 +21,11 @@ char buf[16];
 int main () {
   /* Check whether the given locale name is recognized by the system.  */
   if (setlocale (LC_ALL, "") == NULL) return 1;
-  /* Check whether the abbreviation of the second month is three bytes long.
-     This excludes the UTF-8 encoding.  */
+  /* Check whether in the abbreviation of the second month, the second
+     character (should be U+00E9: LATIN SMALL LETTER E WITH ACUTE) is only
+     one byte long. This excludes the UTF-8 encoding.  */
   t.tm_year = 1975 - 1900; t.tm_mon = 2 - 1; t.tm_mday = 4;
-  if (strftime (buf, sizeof (buf), "%b", &t) != 3) return 1;
+  if (strftime (buf, sizeof (buf), "%b", &t) < 3 || buf[2] != 'v') return 1;
   return 0;
 }
 EOF