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:
authorAlexander Gavrilov <angavrilov@gmail.com>2018-10-29 20:30:31 +0300
committerAlexander Gavrilov <angavrilov@gmail.com>2018-10-29 20:33:15 +0300
commit62e2bbd068dd689620063ccf9e75db71e9931056 (patch)
tree8f8fabae0c1b0f6b2b0f807d316e3d0b5bc50bda /source/blender/depsgraph
parentbd7cb42f3d4c9c9a79fdfce4f2cc1ac54cd8b765 (diff)
Fix T57488: crash in Shrinkwrap constraint due to unsafe multi-threading.
- Constraints must not use mesh_get_eval_final as it isn't thread-safe. - Depsgraph should keep lastDataMask when re-running COW.
Diffstat (limited to 'source/blender/depsgraph')
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc3
1 files changed, 3 insertions, 0 deletions
diff --git a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
index d7575c35e45..f6c3703a703 100644
--- a/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
+++ b/source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
@@ -725,6 +725,7 @@ static void deg_update_copy_on_write_animation(const Depsgraph *depsgraph,
typedef struct ObjectRuntimeBackup {
Object_Runtime runtime;
short base_flag;
+ CustomDataMask lastDataMask;
} ObjectRuntimeBackup;
/* Make a backup of object's evaluation runtime data, additionally
@@ -748,6 +749,7 @@ static void deg_backup_object_runtime(
}
/* Make a backup of base flags. */
object_runtime_backup->base_flag = object->base_flag;
+ object_runtime_backup->lastDataMask = object->lastDataMask;
}
static void deg_restore_object_runtime(
@@ -782,6 +784,7 @@ static void deg_restore_object_runtime(
}
}
object->base_flag = object_runtime_backup->base_flag;
+ object->lastDataMask = object_runtime_backup->lastDataMask;
}
ID *deg_update_copy_on_write_datablock(const Depsgraph *depsgraph,