chiark / gitweb /
systemctl: don't fail if first argument to shutdown isn't 'now' just warn loudly.
authorLennart Poettering <lennart@poettering.net>
Fri, 18 Jun 2010 18:26:05 +0000 (20:26 +0200)
committerLennart Poettering <lennart@poettering.net>
Fri, 18 Jun 2010 18:26:05 +0000 (20:26 +0200)
src/systemctl.c

index 6a7a9bd..444ddf3 100644 (file)
@@ -1741,10 +1741,8 @@ static int shutdown_parse_argv(int argc, char *argv[]) {
                 }
         }
 
-        if (argc > optind && !streq(argv[optind], "now")) {
-                log_error("Expected 'now' argument.");
-                return -EINVAL;
-        }
+        if (argc > optind && !streq(argv[optind], "now"))
+                log_warning("First argument '%s' isn't 'now'. Ignoring.", argv[optind]);
 
         /* We ignore the time argument */
         if (argc > optind + 1)