about summary refs log tree commit diff
path: root/locale/duplocale.c
diff options
context:
space:
mode:
Diffstat (limited to 'locale/duplocale.c')
-rw-r--r--locale/duplocale.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/locale/duplocale.c b/locale/duplocale.c
index 2fa29d14d6..77dfc01046 100644
--- a/locale/duplocale.c
+++ b/locale/duplocale.c
@@ -33,6 +33,10 @@ __libc_lock_define (extern , __libc_setlocale_lock attribute_hidden)
 __locale_t
 __duplocale (__locale_t dataset)
 {
+  /* This static object is returned for newlocale (LC_ALL_MASK, "C").  */
+  if (dataset == &_nl_C_locobj)
+    return dataset;
+
   __locale_t result;
   int cnt;
   size_t names_len = 0;