]> git.ozlabs.org Git - ccan/commitdiff
ccanlint: fix test link when given no arguments.
authorRusty Russell <rusty@rustcorp.com.au>
Tue, 1 Nov 2011 23:01:25 +0000 (09:31 +1030)
committerRusty Russell <rusty@rustcorp.com.au>
Tue, 1 Nov 2011 23:01:25 +0000 (09:31 +1030)
Fallout from commit 758ab1f402b4af3cccac09548b709deca17ef930
(ccanlint: drop -d, interpret any arguments as directories...)

tools/ccanlint/ccanlint.c

index 73a315722e7b2d3bbe434daab4906cfa12a372a4..fe99f7b4cfe6254d436e718fa87b121dd5452435 100644 (file)
@@ -712,15 +712,15 @@ int main(int argc, char *argv[])
        if (verbose >= 4)
                tools_verbose = true;
 
+       /* This links back to the module's test dir. */
+       testlink = talloc_asprintf(NULL, "%s/test", temp_dir(NULL));
+
        /* Defaults to pwd. */
        if (argc == 1) {
                i = 1;
                goto got_dir;
        }
 
-       /* This links back to the module's test dir. */
-       testlink = talloc_asprintf(NULL, "%s/test", temp_dir(NULL));
-
        for (i = 1; i < argc; i++) {
                unsigned int score, total_score;
                dir = argv[i];