summaryrefslogtreecommitdiff
path: root/LibC
diff options
context:
space:
mode:
authorAndreas Kling <awesomekling@gmail.com>2019-04-22 13:00:59 +0200
committerAndreas Kling <awesomekling@gmail.com>2019-04-22 13:00:59 +0200
commit1d02c7b6f171884c3ec971ff5e56a9d19fa29a24 (patch)
treef25240dbd7aec45ed41ca612364e4be4d2633c55 /LibC
parent9f122bff5a2082df40b8e7c839df86f07fbebda6 (diff)
downloadserenity-1d02c7b6f171884c3ec971ff5e56a9d19fa29a24.zip
LibC: Return a default locale from localeconv(). (For GCC 8.3.0)
Diffstat (limited to 'LibC')
-rw-r--r--LibC/locale.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/LibC/locale.cpp b/LibC/locale.cpp
index a17c38f801..62bd414b7c 100644
--- a/LibC/locale.cpp
+++ b/LibC/locale.cpp
@@ -4,6 +4,12 @@
extern "C" {
+static struct lconv default_locale = {
+ ".",
+ ",",
+ "\x03\x03",
+};
+
char* setlocale(int category, const char* locale)
{
dbgprintf("FIXME(LibC): setlocale(%d, %s)\n", category, locale);
@@ -12,7 +18,7 @@ char* setlocale(int category, const char* locale)
struct lconv* localeconv()
{
- assert(false);
+ return &default_locale;
}
}