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:
Diffstat (limited to 'source/blender/editors/render/render_shading.cc')
-rw-r--r--source/blender/editors/render/render_shading.cc6
1 files changed, 3 insertions, 3 deletions
diff --git a/source/blender/editors/render/render_shading.cc b/source/blender/editors/render/render_shading.cc
index f5bd60df2b4..da2290f7372 100644
--- a/source/blender/editors/render/render_shading.cc
+++ b/source/blender/editors/render/render_shading.cc
@@ -1167,7 +1167,7 @@ void SCENE_OT_view_layer_add_lightgroup(wmOperatorType *ot)
ot->prop = RNA_def_string(ot->srna,
"name",
nullptr,
- sizeof(((ViewLayerLightgroup *)NULL)->name),
+ sizeof(((ViewLayerLightgroup *)nullptr)->name),
"Name",
"Name of newly created lightgroup");
}
@@ -2613,7 +2613,7 @@ static void copy_mtex_copybuf(ID *id)
}
if (mtex && *mtex) {
- memcpy(&mtexcopybuf, *mtex, sizeof(MTex));
+ mtexcopybuf = blender::dna::shallow_copy(**mtex);
mtexcopied = 1;
}
else {
@@ -2649,7 +2649,7 @@ static void paste_mtex_copybuf(ID *id)
id_us_min(&(*mtex)->tex->id);
}
- memcpy(*mtex, &mtexcopybuf, sizeof(MTex));
+ **mtex = blender::dna::shallow_copy(mtexcopybuf);
id_us_plus((ID *)mtexcopybuf.tex);
}