chiark / gitweb /
bus-proxyd: explicitly address messages to unique and well-known name
[elogind.git] / src / hostname / hostnamed.c
index b6b5d524c5b5671bc19c0274cea279a494c1854e..0123922c4a2f185583e42ae3f1b8939914e1f136 100644 (file)
@@ -138,7 +138,8 @@ static bool valid_chassis(const char *chassis) {
                         "server\0"
                         "tablet\0"
                         "handset\0"
-                        "watch\0",
+                        "watch\0"
+                        "embedded\0",
                         chassis);
 }
 
@@ -287,7 +288,7 @@ static int context_update_kernel_hostname(Context *c) {
         else
                 hn = "localhost";
 
-        if (sethostname(hn, strlen(hn)) < 0)
+        if (sethostname_idempotent(hn) < 0)
                 return -errno;
 
         return 0;
@@ -684,7 +685,7 @@ int main(int argc, char *argv[]) {
         log_open();
 
         umask(0022);
-        label_init("/etc");
+        mac_selinux_init("/etc");
 
         if (argc != 1) {
                 log_error("This program takes no arguments.");