Refactor: BLI_path_util (part 2)
Use BKE_appdir/tempdir naming prefix for functions extracted from BLI_path_util
This commit is contained in:
@@ -523,7 +523,7 @@ static void blender_crash_handler(int signum)
|
||||
char fname[FILE_MAX];
|
||||
|
||||
if (!G.main->name[0]) {
|
||||
BLI_make_file_string("/", fname, BLI_temp_dir_base(), "crash.blend");
|
||||
BLI_make_file_string("/", fname, BKE_tempdir_base(), "crash.blend");
|
||||
}
|
||||
else {
|
||||
BLI_strncpy(fname, G.main->name, sizeof(fname));
|
||||
@@ -544,10 +544,10 @@ static void blender_crash_handler(int signum)
|
||||
char fname[FILE_MAX];
|
||||
|
||||
if (!G.main->name[0]) {
|
||||
BLI_join_dirfile(fname, sizeof(fname), BLI_temp_dir_base(), "blender.crash.txt");
|
||||
BLI_join_dirfile(fname, sizeof(fname), BKE_tempdir_base(), "blender.crash.txt");
|
||||
}
|
||||
else {
|
||||
BLI_join_dirfile(fname, sizeof(fname), BLI_temp_dir_base(), BLI_path_basename(G.main->name));
|
||||
BLI_join_dirfile(fname, sizeof(fname), BKE_tempdir_base(), BLI_path_basename(G.main->name));
|
||||
BLI_replace_extension(fname, sizeof(fname), ".crash.txt");
|
||||
}
|
||||
|
||||
@@ -579,7 +579,7 @@ static void blender_crash_handler(int signum)
|
||||
}
|
||||
|
||||
/* Delete content of temp dir! */
|
||||
BLI_temp_dir_session_purge();
|
||||
BKE_tempdir_session_purge();
|
||||
|
||||
/* really crash */
|
||||
signal(signum, SIG_DFL);
|
||||
@@ -1557,7 +1557,7 @@ int main(
|
||||
#endif
|
||||
|
||||
/* initialize path to executable */
|
||||
BLI_init_program_path(argv[0]);
|
||||
BKE_appdir_program_path_init(argv[0]);
|
||||
|
||||
BLI_threadapi_init();
|
||||
|
||||
@@ -1636,7 +1636,7 @@ int main(
|
||||
|
||||
/* this is properly initialized with user defs, but this is default */
|
||||
/* call after loading the startup.blend so we can read U.tempdir */
|
||||
BLI_temp_dir_init(U.tempdir);
|
||||
BKE_tempdir_init(U.tempdir);
|
||||
}
|
||||
else {
|
||||
#ifndef WITH_PYTHON_MODULE
|
||||
@@ -1646,7 +1646,7 @@ int main(
|
||||
WM_init(C, argc, (const char **)argv);
|
||||
|
||||
/* don't use user preferences temp dir */
|
||||
BLI_temp_dir_init(NULL);
|
||||
BKE_tempdir_init(NULL);
|
||||
}
|
||||
#ifdef WITH_PYTHON
|
||||
/**
|
||||
|
Reference in New Issue
Block a user