]> git.ozlabs.org Git - ccan/blobdiff - tools/ccanlint/tests/no_trailing_whitespace.c
base64: fix for unsigned chars (e.g. ARM).
[ccan] / tools / ccanlint / tests / no_trailing_whitespace.c
index bba51d8c5a3acd9e65c76044ee09194046ae7193..74f759e7b30c2189e465c920046751ebf356fe3c 100644 (file)
@@ -21,7 +21,7 @@ static char *get_trailing_whitespace(const tal_t *ctx, const char *line)
 }
 
 static void check_trailing_whitespace(struct manifest *m,
-                                     unsigned int *timeleft,
+                                     unsigned int *timeleft UNNEEDED,
                                      struct score *score)
 {
        struct list_head *list;
@@ -34,7 +34,7 @@ static void check_trailing_whitespace(struct manifest *m,
        foreach_ptr(list, &m->c_files, &m->h_files) {
                list_for_each(list, f, list) {
                        char **lines = get_ccan_file_lines(f);
-                       for (i = 0; i < f->num_lines; i++) {
+                       for (i = 0; f->lines[i]; i++) {
                                char *err = get_trailing_whitespace(score,
                                                                    lines[i]);
                                if (err)