Cleanup: remove completely call to test_object_materials in BKE_mesh_new_from_object.

Don't know why this was ever added to start with, BKE_mesh_new_from_object shall never affect ob->data!
This commit is contained in:
2016-07-20 16:40:43 +02:00
parent 1270ab91be
commit dd020caa04

View File

@@ -2441,11 +2441,6 @@ Mesh *BKE_mesh_new_from_object(
BKE_mesh_tessface_ensure(tmpmesh);
}
/* make sure materials get updated in object */
if (ob->data == tmpmesh) { /* XXX To be removed, there is no reason that ob->data would be new tmpmesh... */
test_object_materials(ob, &tmpmesh->id);
}
return tmpmesh;
}