diff options
author | Kévin Dietrich <kevin.dietrich@mailoo.org> | 2021-06-28 14:03:01 +0300 |
---|---|---|
committer | Kévin Dietrich <kevin.dietrich@mailoo.org> | 2021-06-28 14:12:07 +0300 |
commit | 2dbb492268c192f617b812b1cec569eae8a1aed3 (patch) | |
tree | d43e92d71af9433c6073fe311f51348c2a61a818 | |
parent | 1b942ef90c9b4b7fe98af50357aa76b74754f7ff (diff) |
Fix T89455: Cycles crash when rendering a Mesh with autosmooth
The crash was caused by a mistake in 5f9677fe0c533b008b815d7fee0b56509a414ab7
where the pointers to the custom data layers would be overwritten with the one
for the first layer, as CustomData_duplicate_referenced_layer is only about the
first layer. customData_duplicate_referenced_layer_index should be used instead
to duplicate the right layer.
-rw-r--r-- | source/blender/blenkernel/intern/customdata.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/customdata.c b/source/blender/blenkernel/intern/customdata.c index e4717f0b6da..08d0af45e92 100644 --- a/source/blender/blenkernel/intern/customdata.c +++ b/source/blender/blenkernel/intern/customdata.c @@ -2817,7 +2817,7 @@ void CustomData_duplicate_referenced_layers(CustomData *data, int totelem) { for (int i = 0; i < data->totlayer; i++) { CustomDataLayer *layer = &data->layers[i]; - layer->data = CustomData_duplicate_referenced_layer(data, layer->type, totelem); + layer->data = customData_duplicate_referenced_layer_index(data, i, totelem); } } |