summaryrefslogtreecommitdiffstats
path: root/windows.c
diff options
context:
space:
mode:
authorGravatar Lubomir I. Ivanov <neolit123@gmail.com>2013-10-09 16:10:12 +0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-10-09 07:21:04 -0700
commit0b5b671dd9ced84188b032149033de1165fb28b1 (patch)
treed9c0b8fcaa93398b5de1dd3175fbd707654efd43 /windows.c
parent4fee6077af88300960d487bd816349ea6c88456a (diff)
downloadsubsurface-0b5b671dd9ced84188b032149033de1165fb28b1.tar.gz
windows.c: use the USERNAME enviroment variable
system_default_filename(): Use USERNAME, which should work for Windows XP and above. Signed-off-by: Lubomir I. Ivanov <neolit123@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'windows.c')
-rw-r--r--windows.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/windows.c b/windows.c
index eaa389447..ff6e2e036 100644
--- a/windows.c
+++ b/windows.c
@@ -15,7 +15,7 @@ const char *system_default_filename(void)
int len;
/* I don't think this works on Windows */
- user = getenv("LOGNAME");
+ user = getenv("USERNAME");
if (! SUCCEEDED(SHGetFolderPath(NULL, CSIDL_APPDATA, NULL, 0, datapath))) {
datapath[0] = '.';
datapath[1] = '\0';