summaryrefslogtreecommitdiff
path: root/src/locale/c_locale.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2015-06-06 18:53:02 +0000
committerRich Felker <dalias@aerifal.cx>2015-06-06 18:53:02 +0000
commit16bf466532d7328e971012b0731ad493b017ad29 (patch)
tree706444d26d8f70089aadbab6a1e6bfd1711ee00a /src/locale/c_locale.c
parent312eea2ea4f4363fb01b73660c08bfcf43dd3bb4 (diff)
downloadmusl-16bf466532d7328e971012b0731ad493b017ad29.tar.gz
make static C and C.UTF-8 locales available outside of newlocale
Diffstat (limited to 'src/locale/c_locale.c')
-rw-r--r--src/locale/c_locale.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/locale/c_locale.c b/src/locale/c_locale.c
new file mode 100644
index 00000000..77ccf587
--- /dev/null
+++ b/src/locale/c_locale.c
@@ -0,0 +1,15 @@
+#include "locale_impl.h"
+#include <stdint.h>
+
+static const uint32_t empty_mo[] = { 0x950412de, 0, -1, -1, -1 };
+
+const struct __locale_map __c_dot_utf8 = {
+ .map = empty_mo,
+ .map_size = sizeof empty_mo,
+ .name = "C.UTF-8"
+};
+
+const struct __locale_struct __c_locale = { 0 };
+const struct __locale_struct __c_dot_utf8_locale = {
+ .cat[LC_CTYPE] = &__c_dot_utf8
+};