From d7d145d940be0c91d905a4bef85ea80fe15da6d2 Mon Sep 17 00:00:00 2001 From: dmiller Date: Mon, 8 Dec 2014 18:00:29 +0000 Subject: [PATCH] Use MSVCRT _unlink function (unlink was not setting errno) --- nmap-update/nmap-update.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nmap-update/nmap-update.c b/nmap-update/nmap-update.c index d6e78cda6..08b59ae1d 100644 --- a/nmap-update/nmap-update.c +++ b/nmap-update/nmap-update.c @@ -1104,7 +1104,7 @@ static int rename_file(const char *from_filename, const char *to_filename) /* Windows rename doesn't remove the destination if it exists. */ errno = 0; - rc = unlink(to_filename); + rc = _unlink(to_filename); if (rc == -1 && errno != ENOENT) return -1;