]> Savannah Git Hosting - gnulib.git/commitdiff
doc: mention setlocale() issues on OpenBSD
authorPádraig Brady <P@draigBrady.com>
Thu, 14 Jan 2016 10:04:58 +0000 (10:04 +0000)
committerPádraig Brady <P@draigBrady.com>
Thu, 14 Jan 2016 10:38:55 +0000 (10:38 +0000)
* doc/posix-functions/setlocale.texi: Mention setlocale(LC_ALL,"")
never fails, and the need to check categories individually.

ChangeLog
doc/posix-functions/setlocale.texi

index b19edb1e26e2df5f0356ff9b0f27fc85e2091f38..27de5886c93e3473e1569da965e8c35e62d7dc38 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2016-01-14  Pádraig Brady  <P@draigBrady.com>
+
+       doc: mention setlocale() issues on OpenBSD
+       * doc/posix-functions/setlocale.texi: Mention setlocale(LC_ALL,"")
+       never fails, and the need to check categories individually.
+
 2016-01-14  Pádraig Brady  <P@draigBrady.com>
 
        sig2str: list all signals on FreeBSD >= 7
index ee4d477906ff5336402a49c99b938e3ba36dfaad..1da6d13396246df8d54e7132bc54811e63f0cfaf 100644 (file)
@@ -29,4 +29,12 @@ On Cygwin 1.5.x, which doesn't have locales,
 @code{setlocale(LC_ALL,NULL)} always returns @code{"C"}.
 @item
 On Cygwin 1.7.0, only the charset portion of a locale designation is honored.
+@item
+On OpenBSD, @code{setlocale(LC_ALL,"")} will only update categories that
+are deemed appropriate for the @code{LC_ALL} environment value, even if
+there are other categories set to different values in the environment.
+In addition any value is accepted for @code{LC_CTYPE}, and so NULL
+is never returned to indicate a failure to set locale.
+To verify category values, each category must be set individually
+with @code{setlocale(LC_COLLATE,"")} etc.
 @end itemize