chiark / gitweb /
journal-gatewayd: minor cleanup
[elogind.git] / src / hostname / hostnamectl.c
index e7b2b49f29cd8a4b7cf9a7e2891e932e2f1efef1..265c7ecbfe6ccc1c2bf14b1bcce03737cd2979ca 100644 (file)
@@ -23,6 +23,7 @@
 #include <stdbool.h>
 #include <unistd.h>
 #include <getopt.h>
+#include <locale.h>
 #include <string.h>
 #include <sys/timex.h>
 #include <sys/utsname.h>
@@ -402,6 +403,10 @@ static int parse_argv(int argc, char *argv[]) {
                         arg_set_static = true;
                         break;
 
+                case ARG_NO_ASK_PASSWORD:
+                        arg_ask_password = false;
+                        break;
+
                 case '?':
                         return -EINVAL;
 
@@ -507,6 +512,7 @@ int main(int argc, char *argv[]) {
 
         dbus_error_init(&error);
 
+        setlocale(LC_ALL, "");
         log_parse_environment();
         log_open();