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:
authorCampbell Barton <ideasman42@gmail.com>2021-06-13 07:47:22 +0300
committerCampbell Barton <ideasman42@gmail.com>2021-06-13 07:54:54 +0300
commitab382230471c6ee94e82d0fac3f5093e30710628 (patch)
tree9a07f5978a79a687fff983120018eb50f1092a51 /source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc
parentf731bce6cd42eda9c1ca5962b8d1ec99254c478f (diff)
Cleanup: redundant initialization
These were limited to obvious cases. Some less obvious cases were kept as refactoring might make them necessary in future.
Diffstat (limited to 'source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc')
-rw-r--r--source/blender/depsgraph/intern/eval/deg_eval_copy_on_write.cc6
1 files changed, 3 insertions, 3 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 e5d7bd70214..0d367762b00 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
@@ -320,7 +320,6 @@ bool id_copy_inplace_no_main(const ID *id, ID *newid)
* is already allocated. */
bool scene_copy_inplace_no_main(const Scene *scene, Scene *new_scene)
{
- const ID *id_for_copy = &scene->id;
if (G.debug & G_DEBUG_DEPSGRAPH_UUID) {
SEQ_relations_check_uuids_unique_and_report(scene);
@@ -328,9 +327,10 @@ bool scene_copy_inplace_no_main(const Scene *scene, Scene *new_scene)
#ifdef NESTED_ID_NASTY_WORKAROUND
NestedIDHackTempStorage id_hack_storage;
- id_for_copy = nested_id_hack_get_discarded_pointers(&id_hack_storage, &scene->id);
+ const ID *id_for_copy = nested_id_hack_get_discarded_pointers(&id_hack_storage, &scene->id);
+#else
+ const ID *id_for_copy = &scene->id;
#endif
-
bool result = (BKE_id_copy_ex(nullptr,
id_for_copy,
(ID **)&new_scene,