]> git.ozlabs.org Git - ccan/blobdiff - tools/ccanlint/tests/tests_exist.c
base64: fix for unsigned chars (e.g. ARM).
[ccan] / tools / ccanlint / tests / tests_exist.c
index f339b6b9df319b08c48f5c6109eeb6d7f8a17e40..24c4d8776ac241265f371767b1a4292e74f353e2 100644 (file)
@@ -1,5 +1,6 @@
 #include <tools/ccanlint/ccanlint.h>
 #include <ccan/tal/str/str.h>
+#include <ccan/tal/path/path.h>
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
@@ -21,7 +22,7 @@ static struct ccanlint tests_exist = {
 };
 REGISTER_TEST(tests_exist);
 
-static void handle_no_tests(struct manifest *m, struct score *score)
+static void handle_no_tests(struct manifest *m, struct score *score UNNEEDED)
 {
        FILE *run;
        struct ccan_file *i;
@@ -103,10 +104,11 @@ static void handle_no_tests(struct manifest *m, struct score *score)
 }
 
 static void check_tests_exist(struct manifest *m,
-                           unsigned int *timeleft, struct score *score)
+                             unsigned int *timeleft UNNEEDED,
+                             struct score *score)
 {
        struct stat st;
-       char *test_dir = tal_fmt(m, "%s/test", m->dir);
+       char *test_dir = path_join(m, m->dir, "test");
 
        if (lstat(test_dir, &st) != 0) {
                score->error = tal_strdup(score, "No test directory");