chiark / gitweb /
logind: fix delayed execution regression
[elogind.git] / src / login / loginctl.c
index e11ce2a9b99f5d31c39e27f8f6c0bee307eaeaa1..d00fc9ce2610385e783afa1c79184a0ac2544d97 100644 (file)
@@ -42,6 +42,9 @@
 #include "cgroup-util.h"
 #include "spawn-polkit-agent.h"
 #include "verbs.h"
+#include "process-util.h"
+#include "terminal-util.h"
+#include "signal-util.h"
 
 static char **arg_property = NULL;
 static bool arg_all = false;
@@ -1257,7 +1260,7 @@ static int poweroff(int argc, char *argv[], void *userdata) {
 
         assert(bus);
 
-        r = check_inhibitors(bus, "shutdown", "poweroff");
+        r = check_inhibitors(bus, "poweroff", "shutdown");
         if (r < 0)
                 return r;
 
@@ -1286,7 +1289,7 @@ static int reboot(int argc, char *argv[], void *userdata) {
 
         assert(bus);
 
-        r = check_inhibitors(bus, "shutdown", "reboot");
+        r = check_inhibitors(bus, "reboot", "shutdown");
         if (r < 0)
                 return r;
 
@@ -1315,7 +1318,7 @@ static int suspend(int argc, char *argv[], void *userdata) {
 
         assert(bus);
 
-        r = check_inhibitors(bus, "sleep", "suspend");
+        r = check_inhibitors(bus, "suspend", "sleep");
         if (r < 0)
                 return r;
 
@@ -1344,7 +1347,7 @@ static int hibernate(int argc, char *argv[], void *userdata) {
 
         assert(bus);
 
-        r = check_inhibitors(bus, "sleep", "hibernate");
+        r = check_inhibitors(bus, "hibernate", "sleep");
         if (r < 0)
                 return r;
 
@@ -1373,7 +1376,7 @@ static int hybrid_sleep(int argc, char *argv[], void *userdata) {
 
         assert(bus);
 
-        r = check_inhibitors(bus, "sleep", "hybrid-sleep");
+        r = check_inhibitors(bus, "hybrid-sleep", "sleep");
         if (r < 0)
                 return r;