X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=tools%2Fccanlint%2Ftests%2Fdepends_build.c;h=69510a2969b69c6c6468d0085a89850b0428c3e2;hb=bdb8d75154d7aefe01788e5dd5adb11e3c943c11;hp=b578d4b597b7f5b62d98dc5d6d5218b6be89a85b;hpb=453fdc02ce54ff965f9971a3bfd0e1a79b6c98f9;p=ccan diff --git a/tools/ccanlint/tests/depends_build.c b/tools/ccanlint/tests/depends_build.c index b578d4b5..69510a29 100644 --- a/tools/ccanlint/tests/depends_build.c +++ b/tools/ccanlint/tests/depends_build.c @@ -1,6 +1,5 @@ #include #include -#include #include #include #include @@ -36,18 +35,17 @@ static char *build_subdir_objs(struct manifest *m, struct ccan_file *i; list_for_each(&m->c_files, i, list) { - char *fullfile = talloc_asprintf(m, "%s/%s", m->dir, i->name); + char *fullfile = tal_fmt(m, "%s/%s", m->dir, i->name); char *output; i->compiled[ctype] = temp_file(m, "", fullfile); if (!compile_object(m, fullfile, ccan_dir, compiler, flags, i->compiled[ctype], &output)) { - talloc_free(i->compiled[ctype]); + tal_free(i->compiled[ctype]); i->compiled[ctype] = NULL; - return talloc_asprintf(m, - "Dependency %s" - " did not build:\n%s", - m->basename, output); + return tal_fmt(m, + "Dependency %s did not build:\n%s", + m->modname, output); } } return NULL; @@ -90,12 +88,12 @@ static void check_depends_built(struct manifest *m, errstr = build_submodule(i, cflags, COMPILE_NORMAL); if (errstr) { - score->error = talloc_asprintf(score, - "Dependency %s" - " did not" - " build:\n%s", - i->basename, - errstr); + score->error = tal_fmt(score, + "Dependency %s" + " did not" + " build:\n%s", + i->modname, + errstr); return; } }