X-Git-Url: http://git.ozlabs.org/?a=blobdiff_plain;f=tools%2Fccanlint%2Ftests%2Fmain_header_compiles.c;h=5ad2dd415a424961a8a966c5db9cab24d5064d91;hb=bdb8d75154d7aefe01788e5dd5adb11e3c943c11;hp=c6c51837a8f5833f2b7ce735d5d10c147a92f67d;hpb=10e5e329a1a8804ff6461e1724071364cf6be572;p=ccan diff --git a/tools/ccanlint/tests/main_header_compiles.c b/tools/ccanlint/tests/main_header_compiles.c index c6c51837..5ad2dd41 100644 --- a/tools/ccanlint/tests/main_header_compiles.c +++ b/tools/ccanlint/tests/main_header_compiles.c @@ -1,7 +1,5 @@ #include #include -#include -#include #include #include #include @@ -50,8 +48,8 @@ static void check_includes_build(struct manifest *m, if (fd < 0) err(1, "Creating temporary file %s", tmpsrc); - contents = talloc_asprintf(tmpsrc, "#include \n", - m->modname, m->basename); + contents = tal_fmt(tmpsrc, "#include \n", + m->modname, m->basename); if (write(fd, contents, strlen(contents)) != strlen(contents)) err(1, "writing to temporary file %s", tmpsrc); close(fd); @@ -61,7 +59,7 @@ static void check_includes_build(struct manifest *m, score->pass = true; score->score = score->total; } else { - score->error = talloc_asprintf(score, + score->error = tal_fmt(score, "#include of the main header file:\n%s", cmdout); }