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:
-rw-r--r--source/blender/blenloader/intern/writefile.c6
-rw-r--r--source/blender/windowmanager/intern/wm_files.c4
2 files changed, 7 insertions, 3 deletions
diff --git a/source/blender/blenloader/intern/writefile.c b/source/blender/blenloader/intern/writefile.c
index f9f66ed8504..dc5a0dbeafa 100644
--- a/source/blender/blenloader/intern/writefile.c
+++ b/source/blender/blenloader/intern/writefile.c
@@ -273,7 +273,7 @@ static void mywrite( WriteData *wd, void *adr, int len)
* @param write_flags Write parameters
* @warning Talks to other functions with global parameters
*/
-static WriteData *bgnwrite(int file, MemFile *compare, MemFile *current, int write_flags)
+static WriteData *bgnwrite(int file, MemFile *compare, MemFile *current)
{
WriteData *wd= writedata_new(file);
@@ -2349,7 +2349,7 @@ static void write_global(WriteData *wd, int fileflags, Main *mainvar)
fg.curscene= screen->scene;
fg.displaymode= G.displaymode;
fg.winpos= G.winpos;
- fg.fileflags= (fileflags & ~G_FILE_NO_UI); // prevent to save this, is not good convention, and feature with concerns...
+ fg.fileflags= (fileflags & ~(G_FILE_NO_UI|G_FILE_RELATIVE_REMAP)); // prevent to save this, is not good convention, and feature with concerns...
fg.globalf= G.f;
BLI_strncpy(fg.filename, mainvar->name, sizeof(fg.filename));
@@ -2384,7 +2384,7 @@ static int write_file_handle(Main *mainvar, int handle, MemFile *compare, MemFil
blo_split_main(&mainlist, mainvar);
- wd= bgnwrite(handle, compare, current, write_flags);
+ wd= bgnwrite(handle, compare, current);
sprintf(buf, "BLENDER%c%c%.3d", (sizeof(void*)==8)?'-':'_', (ENDIAN_ORDER==B_ENDIAN)?'V':'v', BLENDER_VERSION);
mywrite(wd, buf, 12);
diff --git a/source/blender/windowmanager/intern/wm_files.c b/source/blender/windowmanager/intern/wm_files.c
index b24e0333bac..1264f496103 100644
--- a/source/blender/windowmanager/intern/wm_files.c
+++ b/source/blender/windowmanager/intern/wm_files.c
@@ -374,6 +374,10 @@ int WM_read_homefile(bContext *C, wmOperator *op)
if (wmbase.first == NULL) wm_clear_default_size(C);
}
+ /* prevent buggy files that had G_FILE_RELATIVE_REMAP written out by mistake. Screws up autosaves otherwise
+ * can remove this eventually, only in a 2.53 and older, now its not written */
+ G.fileflags &= ~G_FILE_RELATIVE_REMAP;
+
/* match the read WM with current WM */
wm_window_match_do(C, &wmbase);
WM_check(C); /* opens window(s), checks keymaps */