]> git.ipfire.org Git - thirdparty/systemd.git/blobdiff - src/fstab-generator/fstab-generator.c
coccinelle: make use of SYNTHETIC_ERRNO
[thirdparty/systemd.git] / src / fstab-generator / fstab-generator.c
index 15ac20dd713554953ef0119f7bb5f299bccb4644..c74ad075c045a52cb9722a6cc5c52b808557296d 100644 (file)
@@ -870,10 +870,9 @@ static int determine_root(void) {
 static int run(int argc, char *argv[]) {
         int r;
 
-        if (argc > 1 && argc != 4) {
-                log_error("This program takes three or no arguments.");
-                return -EINVAL;
-        }
+        if (argc > 1 && argc != 4)
+                return log_error_errno(SYNTHETIC_ERRNO(EINVAL),
+                                       "This program takes three or no arguments.");
 
         if (argc > 1)
                 arg_dest = argv[1];