diff options
author | Campbell Barton <ideasman42@gmail.com> | 2012-03-24 10:18:31 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2012-03-24 10:18:31 +0400 |
commit | 69e6894b15271884623ea6f56ead06db83acbe99 (patch) | |
tree | b68200606afaca06cf7552f6b12fc20ebd30d487 /source/blender/blenlib/intern/listbase.c | |
parent | 7b99ae0ad3017e373be2a344e30d190b70ca66b4 (diff) |
style cleanup: follow style guide for formatting of if/for/while loops, and else if's
Diffstat (limited to 'source/blender/blenlib/intern/listbase.c')
-rw-r--r-- | source/blender/blenlib/intern/listbase.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source/blender/blenlib/intern/listbase.c b/source/blender/blenlib/intern/listbase.c index 71077f8e467..fecaa507b5c 100644 --- a/source/blender/blenlib/intern/listbase.c +++ b/source/blender/blenlib/intern/listbase.c @@ -114,7 +114,7 @@ void BLI_remlink(ListBase *listbase, void *vlink) int BLI_remlink_safe(ListBase *listbase, void *vlink) { - if(BLI_findindex(listbase, vlink) != -1) { + if (BLI_findindex(listbase, vlink) != -1) { BLI_remlink(listbase, vlink); return 1; } @@ -189,7 +189,7 @@ void BLI_sortlist(ListBase *listbase, int (*cmp)(void *, void *)) BLI_remlink(listbase, current); - while(previous && cmp(previous, current) == 1) + while (previous && cmp(previous, current) == 1) { previous = previous->prev; } @@ -457,7 +457,7 @@ int BLI_findstringindex(const ListBase *listbase, const char *id, const int offs while (link) { id_iter= ((const char *)link) + offset; - if(id[0] == id_iter[0] && strcmp(id, id_iter)==0) + if (id[0] == id_iter[0] && strcmp(id, id_iter)==0) return i; i++; link= link->next; @@ -474,7 +474,7 @@ void BLI_duplicatelist(ListBase *dst, const ListBase *src) src_link= src->first; dst->first= dst->last= NULL; - while(src_link) { + while (src_link) { dst_link= MEM_dupallocN(src_link); BLI_addtail(dst, dst_link); |