chiark / gitweb /
systemctl: check the value from start_unit_one
authorThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Fri, 6 Dec 2013 18:48:08 +0000 (19:48 +0100)
committerThomas Hindoe Paaboel Andersen <phomes@gmail.com>
Fri, 6 Dec 2013 20:13:46 +0000 (21:13 +0100)
introduced in f459b6025f9368116d8c410376546c157314c205

src/systemctl/systemctl.c

index 561572c..6b6cb3d 100644 (file)
@@ -2145,7 +2145,7 @@ static int start_unit(sd_bus *bus, char **args) {
 
                         q = start_unit_one(bus, method, *name, mode, &error, s);
                         if (q < 0) {
-                                r = translate_bus_error_to_exit_status(r, &error);
+                                r = translate_bus_error_to_exit_status(q, &error);
                                 sd_bus_error_free(&error);
                         }
                 }