From 314b43b4f075a527be1b800848869765f4fe16a4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Ekl=C3=B6f?= Date: Sat, 19 Jan 2019 20:50:02 +0100 Subject: [PATCH] main: initialize locale This affects e.g. the clock module, which (by default) formats the date according to the locale's preferred format. --- main.c | 18 ++++++++++-------- 1 file changed, 10 insertions(+), 8 deletions(-) diff --git a/main.c b/main.c index 5fc1a55..f765eb7 100644 --- a/main.c +++ b/main.c @@ -1,14 +1,14 @@ +#include +#include +#include +#include +#include +#include +#include #include #include -#include -#include -#include -#include -#include -#include - #include -#include +#include #include #include @@ -91,6 +91,8 @@ out: int main(int argc, const char *const *argv) { + setlocale(LC_ALL, ""); + const struct sigaction sa = {.sa_handler = &signal_handler}; sigaction(SIGINT, &sa, NULL); sigaction(SIGTERM, &sa, NULL);