diff options
author | Hans Goudey <h.goudey@me.com> | 2022-08-29 22:55:04 +0300 |
---|---|---|
committer | Hans Goudey <h.goudey@me.com> | 2022-08-29 22:55:04 +0300 |
commit | dc92c5766f3d74071d736ae3a3d41a03a6ff2352 (patch) | |
tree | 474727c5f947bc02b627f8347a5bdac22aa7499e /source | |
parent | 50e5c787995c2a1a96edfef5479fe40c3a307c7f (diff) | |
parent | b814f64f4ab26f76ef7b75901877c170f7198570 (diff) |
Merge branch 'blender-v3.3-release'
Diffstat (limited to 'source')
-rw-r--r-- | source/blender/blenkernel/intern/attribute.cc | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/attribute.cc b/source/blender/blenkernel/intern/attribute.cc index b6d39486313..495a2c82332 100644 --- a/source/blender/blenkernel/intern/attribute.cc +++ b/source/blender/blenkernel/intern/attribute.cc @@ -288,6 +288,10 @@ CustomDataLayer *BKE_id_attribute_duplicate(ID *id, const char *name, ReportList bool BKE_id_attribute_remove(ID *id, const char *name, ReportList *reports) { using namespace blender::bke; + if (!name || name[0] == '\0') { + BKE_report(reports, RPT_ERROR, "The attribute name must not be empty"); + return false; + } if (BKE_id_attribute_required(id, name)) { BKE_report(reports, RPT_ERROR, "Attribute is required and can't be removed"); return false; |