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:
authorCampbell Barton <ideasman42@gmail.com>2013-07-28 10:37:58 +0400
committerCampbell Barton <ideasman42@gmail.com>2013-07-28 10:37:58 +0400
commitc4a50e9aeb589045b857fea878fb86faba39dd3c (patch)
tree650846ab417fc96c646da2bed9b8edd16e2a8147 /source/blender/blenkernel/intern/material.c
parent0cb9a8311364edbc65fa207678341b88b986749d (diff)
remove unneeded NULL checks, add one for give_matarar() return value.
Diffstat (limited to 'source/blender/blenkernel/intern/material.c')
-rw-r--r--source/blender/blenkernel/intern/material.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c
index 300beae1078..6dc3c6d7bc6 100644
--- a/source/blender/blenkernel/intern/material.c
+++ b/source/blender/blenkernel/intern/material.c
@@ -1176,7 +1176,9 @@ int object_remove_material_slot(Object *ob)
totcolp = give_totcolp(ob);
matarar = give_matarar(ob);
- if (*matarar == NULL) return FALSE;
+ if (ELEM(NULL, matarar, *matarar)) {
+ return false;
+ }
/* can happen on face selection in editmode */
if (ob->actcol > ob->totcol) {