]> git.ipfire.org Git - thirdparty/ccache.git/commitdiff
Also check for %APPDATA% on win32 to use as home
authorRamiro Polla <ramiro.polla@gmail.com>
Wed, 22 Sep 2010 02:06:50 +0000 (23:06 -0300)
committerJoel Rosdahl <joel@rosdahl.net>
Sun, 26 Sep 2010 20:12:13 +0000 (22:12 +0200)
util.c

diff --git a/util.c b/util.c
index 0ea67b4c234e873188c9bccf4634b821ee71057a..905bd24b664679e6e72a5c8d5141ce02573c65ac 100644 (file)
--- a/util.c
+++ b/util.c
@@ -876,6 +876,12 @@ get_home_directory(void)
        if (p) {
                return p;
        }
+#ifdef _WIN32
+       p = getenv("APPDATA");
+       if (p) {
+               return p;
+       }
+#endif
 #ifdef HAVE_GETPWUID
        {
                struct passwd *pwd = getpwuid(getuid());