bugfix [#23674] Fix for texture path corruptions (bug 23337)
from Mathew Burrack (mburrack) ...also applied a fix so this flag wont be written but including this patch for older startup.blend's. --- from the tracker I've created a patch for the texture path corruption bug, 23337. Basically, G_FILE_RELATIVE_REMAP was improperly getting saved out to the startup.blend file, causing issues when the autosave timer went off. The proper fix is to mask out that flag so it doesn't get written out to .blend files itself, but since that doesn't fix any pre-existing startup.blend files, I just mask it out when startup.blend is read in instead. I've tested it locally and so far, it seems to fix all the issues I've had with texture image paths getting corrupted. I haven't figured out how to properly test the remap-on-save option in the save as dialog, though, so I don't know if I accidentally broke that or not (although I don't see how I could have).
This commit is contained in:
@@ -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 */
|
||||
|
||||
Reference in New Issue
Block a user