From: Kevin Locke Date: Fri, 23 Sep 2016 03:33:04 +0000 (-0600) Subject: configurator: Replace unlink with remove X-Git-Url: http://git.ozlabs.org/?p=ccan;a=commitdiff_plain;h=891b43ea4b6d09db68ee83f7086b5673e2806733 configurator: Replace unlink with remove Although Windows provides unlink, using it adds complication due to the lack of unistd.h which must be included to define the function on POSIX systems. Instead, use remove, which C89 requires to be in stdio.h. Signed-off-by: Kevin Locke Reviewed-by: David Gibson Signed-off-by: David Gibson --- diff --git a/tools/configurator/configurator.c b/tools/configurator/configurator.c index 67dadc61..e322c76c 100644 --- a/tools/configurator/configurator.c +++ b/tools/configurator/configurator.c @@ -639,8 +639,8 @@ int main(int argc, const char *argv[]) run_test(cmd, &tests[i]); free(cmd); - unlink(OUTPUT_FILE); - unlink(INPUT_FILE); + remove(OUTPUT_FILE); + remove(INPUT_FILE); printf("/* Generated by CCAN configurator */\n" "#ifndef CCAN_CONFIG_H\n"