Cleanup: redundant initialization
These were limited to obvious cases. Some less obvious cases were kept as refactoring might make them necessary in future.
This commit is contained in:
@@ -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,
|
||||
|
||||
Reference in New Issue
Block a user