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:
authorTon Roosendaal <ton@blender.org>2013-02-13 20:52:14 +0400
committerTon Roosendaal <ton@blender.org>2013-02-13 20:52:14 +0400
commitda4711632c729d54dc3d425d905dec926966f79c (patch)
tree84b8d1c20493b7d727f1a581232448e13a2fca3c /source/blender/blenloader
parent909d64079a228dfa9cccf8ed718efc322a038e7e (diff)
Fix for splitting startup and userpref:
The do-version handling for Userdef is outside file reading, which makes it needed to store the file version in UserDef, so it gets the correct version to handle. Thanks Antonis R. for pointing at the omission! Also removed the mindboggling define. If you do such, then make it like "MAIN_VERSION_OLDER_THAN() or so. In general version hacking could be limited much better... ask me before even thinking to add one, most optimal is to do it in a way it's not depending on a version ever - forward/backward compatible.
Diffstat (limited to 'source/blender/blenloader')
-rw-r--r--source/blender/blenloader/intern/readfile.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenloader/intern/readfile.c b/source/blender/blenloader/intern/readfile.c
index de5e69b741a..6fba30aa060 100644
--- a/source/blender/blenloader/intern/readfile.c
+++ b/source/blender/blenloader/intern/readfile.c
@@ -8881,6 +8881,10 @@ static BHead *read_userdef(BlendFileData *bfd, FileData *fd, BHead *bhead)
bfd->user = user= read_struct(fd, bhead, "user def");
+ /* User struct has separate do-version handling */
+ user->versionfile = bfd->main->versionfile;
+ user->subversionfile = bfd->main->subversionfile;
+
/* read all data into fd->datamap */
bhead = read_data_into_oldnewmap(fd, bhead, "user def");