From c90fbbf75a28bd2044b780e70db5f10b88869ac0 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 10 Sep 2022 16:03:40 +1000 Subject: WM: update comment for wm_autosave_location auto-save fallback --- source/blender/windowmanager/intern/wm_files.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) (limited to 'source/blender') diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c index 6d2248ba354..0e43ed5509a 100644 --- a/source/blender/windowmanager/intern/wm_files.c +++ b/source/blender/windowmanager/intern/wm_files.c @@ -1917,12 +1917,11 @@ static void wm_autosave_location(char filepath[FILE_MAX]) } const char *tempdir_base = BKE_tempdir_base(); + /* NOTE(@campbellbarton): It's strange that this is only used on WIN32. + * From reading commits it seems accessing the temporary directory used to be less reliable. + * If this is still the case on WIN32 - other features such as copy-paste will also fail. + * We could support #BLENDER_USER_AUTOSAVE on all platforms or remove it entirely. */ #ifdef WIN32 - /* XXX Need to investigate how to handle default location of `/tmp/` - * This is a relative directory on Windows, and it may be found. Example: - * Blender installed on `D:\` drive, `D:\` drive has `D:\tmp\` Now, `BLI_exists()` - * will find `/tmp/` exists, but #BLI_windows_get_default_root_dir will expand this to `C:\`. - * If there is no `C:\tmp` autosave fails. */ if (!BLI_exists(tempdir_base)) { const char *savedir = BKE_appdir_folder_id_create(BLENDER_USER_AUTOSAVE, NULL); if (savedir) { -- cgit v1.2.3