commit 8f6aa9b855d6f3b4251141a82a06227381a8ac2f
Author:     Quentin Rameau <[email protected]>
AuthorDate: Thu Jun 16 11:24:39 2016 +0200
Commit:     Quentin Rameau <[email protected]>
CommitDate: Fri Jun 17 15:45:08 2016 +0200

    [driver] merge input check with other argument checks

diff --git a/driver/posix/scc.c b/driver/posix/scc.c
index 1b6cf5b..d3e6b9e 100644
--- a/driver/posix/scc.c
+++ b/driver/posix/scc.c
@@ -446,12 +446,9 @@ main(int argc, char *argv[])
                usage();
        } ARGEND
 
-       if (Eflag && (Sflag || kflag) || argc > 1 && cflag && outfile)
+       if (Eflag && (Sflag || kflag) || argc > 1 && cflag && outfile || !argc)
                usage();
 
-       if (!argc)
-               die("scc: fatal error: no input file");
-
        for (; *argv; ++argv)
                build(*argv);
 

Reply via email to