Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCampbell Barton <ideasman42@gmail.com>2020-10-05 01:40:01 +0300
committerCampbell Barton <ideasman42@gmail.com>2020-10-05 01:43:57 +0300
commit659f81f1cbc3189c3a00cf290f4bade7614c4e91 (patch)
tree163173eeab0b5361bc6bb04025dbe5446139f7a3
parentffa71526266930584e2d7a93f4c9f8539fafdd2c (diff)
Correct last commit (where_is_temp refactor)
Changes didn't account the case when mkdtemp failed. Previously the copying the string wasn't needed in this case.
-rw-r--r--source/blender/blenkernel/intern/appdir.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/appdir.c b/source/blender/blenkernel/intern/appdir.c
index 018bb47403a..feed56f733d 100644
--- a/source/blender/blenkernel/intern/appdir.c
+++ b/source/blender/blenkernel/intern/appdir.c
@@ -1087,7 +1087,8 @@ static void tempdir_session_create(char *tempdir_session,
CLOG_WARN(&LOG,
"Could not generate a temp file name for '%s', falling back to '%s'",
tmp_name,
- tempdir_session);
+ tempdir);
+ BLI_strncpy(tempdir_session, tmp_name, tempdir_session_len);
}
MEM_freeN(tmp_name);