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:
authorBastien Montagne <montagne29@wanadoo.fr>2015-01-26 18:03:11 +0300
committerBastien Montagne <montagne29@wanadoo.fr>2015-01-26 18:59:24 +0300
commitfca515838e70f8bec7028b840bb921a1be9fabbb (patch)
tree1752923de19eca5f01ca4cfb5754fd4d1f13d934 /source/blender/blenkernel/intern/mball.c
parentd44890ee75634052f325531766a661a5bcef628f (diff)
Cleanup: strcmp/strncmp -> STREQ/STREQLEN (in boolean usage).
Makes usage of those funcs much more clear, we even had mixed '!strcmp(foo, bar)' and 'strcmp(foo, bar) == 0' in several places...
Diffstat (limited to 'source/blender/blenkernel/intern/mball.c')
-rw-r--r--source/blender/blenkernel/intern/mball.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/source/blender/blenkernel/intern/mball.c b/source/blender/blenkernel/intern/mball.c
index 5649164a273..ce20636233a 100644
--- a/source/blender/blenkernel/intern/mball.c
+++ b/source/blender/blenkernel/intern/mball.c
@@ -468,7 +468,7 @@ bool BKE_mball_is_basis_for(Object *ob1, Object *ob2)
BLI_split_name_num(basis1name, &basis1nr, ob1->id.name + 2, '.');
BLI_split_name_num(basis2name, &basis2nr, ob2->id.name + 2, '.');
- if (!strcmp(basis1name, basis2name)) {
+ if (STREQ(basis1name, basis2name)) {
return BKE_mball_is_basis(ob1);
}
else {
@@ -503,7 +503,7 @@ void BKE_mball_properties_copy(Scene *scene, Object *active_object)
/* Object ob has to be in same "group" ... it means, that it has to have
* same base of its name */
- if (strcmp(obname, basisname) == 0) {
+ if (STREQ(obname, basisname)) {
MetaBall *mb = ob->data;
/* Copy properties from selected/edited metaball */
@@ -545,7 +545,7 @@ Object *BKE_mball_basis_find(Scene *scene, Object *basis)
BLI_split_name_num(obname, &obnr, ob->id.name + 2, '.');
/* object ob has to be in same "group" ... it means, that it has to have same base of its name */
- if (strcmp(obname, basisname) == 0) {
+ if (STREQ(obname, basisname)) {
if (obnr < basisnr) {
basis = ob;
basisnr = obnr;
@@ -1679,7 +1679,7 @@ static float init_meta(EvaluationContext *eval_ctx, PROCESS *process, Scene *sce
int nr;
BLI_split_name_num(name, &nr, bob->id.name + 2, '.');
- if (strcmp(obname, name) == 0) {
+ if (STREQ(obname, name)) {
mb = bob->data;
if (mb->editelems) ml = mb->editelems->first;
@@ -2243,7 +2243,7 @@ static void mball_count(EvaluationContext *eval_ctx, PROCESS *process, Scene *sc
/* object ob has to be in same "group" ... it means, that it has to have
* same base of its name */
- if (strcmp(obname, basisname) == 0) {
+ if (STREQ(obname, basisname)) {
MetaBall *mb = ob->data;
/* if object is in edit mode, then dynamic list of all MetaElems