Fix T82019 Crash loading 2.78 splash demo.
The versioning code to default to old booleans for old files was faulty because really old files had a 'solver' field (later removed, but then added back for new booleans).
This commit is contained in:
parent
bc0a33a812
commit
ca83649b7d
Notes:
blender-bot
2023-02-13 23:17:13 +01:00
Referenced by issue #82019, New boolean causes 2.78 demo file to fail to load
|
@ -705,14 +705,12 @@ void blo_do_versions_290(FileData *fd, Library *UNUSED(lib), Main *bmain)
|
|||
}
|
||||
|
||||
/* Solver and Collections for Boolean. */
|
||||
if (!DNA_struct_elem_find(fd->filesdna, "BooleanModifierData", "char", "solver")) {
|
||||
for (Object *object = bmain->objects.first; object != NULL; object = object->id.next) {
|
||||
LISTBASE_FOREACH (ModifierData *, md, &object->modifiers) {
|
||||
if (md->type == eModifierType_Boolean) {
|
||||
BooleanModifierData *bmd = (BooleanModifierData *)md;
|
||||
bmd->solver = eBooleanModifierSolver_Fast;
|
||||
bmd->flag = eBooleanModifierFlag_Object;
|
||||
}
|
||||
for (Object *object = bmain->objects.first; object != NULL; object = object->id.next) {
|
||||
LISTBASE_FOREACH (ModifierData *, md, &object->modifiers) {
|
||||
if (md->type == eModifierType_Boolean) {
|
||||
BooleanModifierData *bmd = (BooleanModifierData *)md;
|
||||
bmd->solver = eBooleanModifierSolver_Fast;
|
||||
bmd->flag = eBooleanModifierFlag_Object;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue