diff options
author | Campbell Barton <ideasman42@gmail.com> | 2014-01-16 12:15:53 +0400 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2014-01-16 12:15:53 +0400 |
commit | af93ebcb503293e382f74c2d33554504269d4815 (patch) | |
tree | e4490d7be44e3532e1655f82c7a7aeb11cc5785c /source/blender/blenlib | |
parent | bb1a7e4d8722fda09a3294eea56a537b6f043dd3 (diff) |
Code Cleanup: style and redundant casts
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r-- | source/blender/blenlib/intern/scanfill.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/storage.c | 2 | ||||
-rw-r--r-- | source/blender/blenlib/intern/string.c | 6 | ||||
-rw-r--r-- | source/blender/blenlib/intern/winstuff_dir.c | 6 |
4 files changed, 10 insertions, 6 deletions
diff --git a/source/blender/blenlib/intern/scanfill.c b/source/blender/blenlib/intern/scanfill.c index c4cefadb815..d1eb72563a1 100644 --- a/source/blender/blenlib/intern/scanfill.c +++ b/source/blender/blenlib/intern/scanfill.c @@ -699,7 +699,7 @@ static unsigned int scanfill(ScanFillContext *sf_ctx, PolyFill *pf, const int fl ed3 = sc1->edge_first; while (ed3) { - if ( (ed3->v1 == v1 && ed3->v2 == v3) || (ed3->v1 == v3 && ed3->v2 == v1) ) { + if ((ed3->v1 == v1 && ed3->v2 == v3) || (ed3->v1 == v3 && ed3->v2 == v1)) { if (twoconnected || ed3->f == SF_EDGE_BOUNDARY) { BLI_remlink((ListBase *)&(sc1->edge_first), ed3); BLI_addtail(&sf_ctx->filledgebase, ed3); diff --git a/source/blender/blenlib/intern/storage.c b/source/blender/blenlib/intern/storage.c index 6f03529d37c..de40cab425d 100644 --- a/source/blender/blenlib/intern/storage.c +++ b/source/blender/blenlib/intern/storage.c @@ -486,7 +486,7 @@ int BLI_exists(const char *name) unsigned int old_error_mode; len = wcslen(tmp_16); - if (len > 3 && (tmp_16[len - 1] == L'\\' || tmp_16[len - 1] == L'/') ) + if (len > 3 && (tmp_16[len - 1] == L'\\' || tmp_16[len - 1] == L'/')) tmp_16[len - 1] = '\0'; /* change error mode so user does not get a "no disk in drive" popup diff --git a/source/blender/blenlib/intern/string.c b/source/blender/blenlib/intern/string.c index 0ce40f717d4..6b738fab45e 100644 --- a/source/blender/blenlib/intern/string.c +++ b/source/blender/blenlib/intern/string.c @@ -513,17 +513,17 @@ int BLI_natstrcmp(const char *s1, const char *s2) c1 = tolower(s1[d1]); c2 = tolower(s2[d2]); - if (isdigit(c1) && isdigit(c2) ) { + if (isdigit(c1) && isdigit(c2)) { int numcompare = left_number_strcmp(s1 + d1, s2 + d2, &tiebreaker); if (numcompare != 0) return numcompare; d1++; - while (isdigit(s1[d1]) ) + while (isdigit(s1[d1])) d1++; d2++; - while (isdigit(s2[d2]) ) + while (isdigit(s2[d2])) d2++; c1 = tolower(s1[d1]); diff --git a/source/blender/blenlib/intern/winstuff_dir.c b/source/blender/blenlib/intern/winstuff_dir.c index 4082681ee11..90250de1683 100644 --- a/source/blender/blenlib/intern/winstuff_dir.c +++ b/source/blender/blenlib/intern/winstuff_dir.c @@ -21,12 +21,16 @@ * Windows-posix compatibility layer for opendir/readdir/closedir */ -/** \file blender/blenlib/intern/winstuff.c +/** \file blender/blenlib/intern/winstuff_dir.c * \ingroup bli + * + * Posix compatibility functions for windows dealing with DIR + * (opendir, readdir, closedir) */ #if defined(WIN32) && !defined(FREE_WINDOWS) +/* standalone for inclusion in binaries other then blender */ # ifdef USE_STANDALONE # define MEM_mallocN(size, str) ((void)str, malloc(size)) # define MEM_callocN(size, str) ((void)str, calloc(size, 1)) |