diff options
author | tjw <tjw@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2006-09-13 22:55:53 +0000 |
---|---|---|
committer | tjw <tjw@edf5b092-35ff-0310-97b2-ce42778d08ea> | 2006-09-13 22:55:53 +0000 |
commit | f84ccd76b3307be22b7be1e4baf9a432822c67e3 (patch) | |
tree | e07df2b168ec25d683f55276632c73edcff29298 /code | |
parent | 224d1edf37216e46d7defd8351c2546d3c85bdfe (diff) | |
download | ioquake3-aero-f84ccd76b3307be22b7be1e4baf9a432822c67e3.tar.gz ioquake3-aero-f84ccd76b3307be22b7be1e4baf9a432822c67e3.zip |
Bug 2813
* Do not detect a seperate homepath on win95, win98, or winme since it's not
truly a user-specific dir and therefore provides no advantage
* Use CSIDL_APPDATA instead of CSIDL_LOCAL_APPDATA. This means that
user-specific game data is now allowed to be part of a user's Roaming Profile
git-svn-id: svn://svn.icculus.org/quake3/trunk@907 edf5b092-35ff-0310-97b2-ce42778d08ea
Diffstat (limited to 'code')
-rw-r--r-- | code/win32/win_shared.c | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/code/win32/win_shared.c b/code/win32/win_shared.c index 4bbd509..98c0098 100644 --- a/code/win32/win_shared.c +++ b/code/win32/win_shared.c @@ -288,10 +288,17 @@ char *Sys_DefaultHomePath(void) { TCHAR szPath[MAX_PATH]; static char path[MAX_OSPATH]; - if( !SUCCEEDED( SHGetFolderPath( NULL, CSIDL_LOCAL_APPDATA, + // do not bother using a seperate home directory on versions of + // windows that do not offer true per-user home directories + // (win98, win95, winme) + g_wv.osversion.dwOSVersionInfoSize = sizeof( g_wv.osversion ); + GetVersionEx( &g_wv.osversion ); + if( g_wv.osversion.dwPlatformId == VER_PLATFORM_WIN32_WINDOWS ) + return NULL; + + if( !SUCCEEDED( SHGetFolderPath( NULL, CSIDL_APPDATA, NULL, 0, szPath ) ) ) { - return NULL; } Q_strncpyz( path, szPath, sizeof(path) ); |