]> git.ipfire.org Git - thirdparty/sarg.git/commitdiff
Test for an absolute path on Windows
authorFrederic Marchal <fmarchal@users.sourceforge.net>
Sat, 26 Jan 2013 18:40:25 +0000 (19:40 +0100)
committerFrederic Marchal <fmarchal@users.sourceforge.net>
Sat, 26 Jan 2013 18:40:25 +0000 (19:40 +0100)
The code to test for an absolute path on Windows was not compiled because
the constant to enable that code is not supported.

util.c

diff --git a/util.c b/util.c
index 6ff809bb7f8309556a7e19454650f200fc30598b..92dfd60e4f53fcc3000758b4f132ca1de0bc5043 100644 (file)
--- a/util.c
+++ b/util.c
@@ -380,7 +380,7 @@ long long int my_atoll (const char *nptr)
 int is_absolute(const char *path)
 {
        if (*path=='/') return(1);
-#ifdef WINDOWS
+#ifdef _WIN32
        if (isalpha(path[0]) && path[1]==':') return(1);
 #endif
        return(0);