From d1f6c2e7bb59e12f381bffdbaf8274936f404b7e Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Fri, 2 Oct 2020 20:11:51 +1000 Subject: Fix userpref.blend using version from startup.blend Version patching userpref.blend wasn't using the correct version, causing settings not to be properly updated. This seems the likely cause of T70196 and similar bugs. --- source/blender/blenloader/intern/versioning_userdef.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/blender/blenloader/intern') diff --git a/source/blender/blenloader/intern/versioning_userdef.c b/source/blender/blenloader/intern/versioning_userdef.c index 691258a5a8c..0265bd85f14 100644 --- a/source/blender/blenloader/intern/versioning_userdef.c +++ b/source/blender/blenloader/intern/versioning_userdef.c @@ -303,10 +303,10 @@ static bool keymap_item_has_invalid_wm_context_data_path(wmKeyMapItem *kmi, } /* patching UserDef struct and Themes */ -void BLO_version_defaults_userpref_blend(Main *bmain, UserDef *userdef) +void BLO_version_defaults_userpref_blend(UserDef *userdef) { - -#define USER_VERSION_ATLEAST(ver, subver) MAIN_VERSION_ATLEAST(bmain, ver, subver) + /* #UserDef & #Main happen to have the same struct member. */ +#define USER_VERSION_ATLEAST(ver, subver) MAIN_VERSION_ATLEAST(userdef, ver, subver) /* the UserDef struct is not corrected with do_versions() .... ugh! */ if (userdef->wheellinescroll == 0) { -- cgit v1.2.3