diff options
author | Campbell Barton <ideasman42@gmail.com> | 2019-03-17 11:19:12 +0300 |
---|---|---|
committer | Campbell Barton <ideasman42@gmail.com> | 2019-03-17 13:00:56 +0300 |
commit | 6cbd2e5c4d4592cb12d657c5c433a37db98c90a1 (patch) | |
tree | f7fada7a0a79e47ddfc94bec61d4ad7108681f59 | |
parent | d23452897bd3f92d7da1a987f3241a6d2537fbc3 (diff) |
Cleanup: remove redundant check
-rw-r--r-- | source/blender/blenlib/intern/string.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/blender/blenlib/intern/string.c b/source/blender/blenlib/intern/string.c index dbec1a3153c..a1228045a4d 100644 --- a/source/blender/blenlib/intern/string.c +++ b/source/blender/blenlib/intern/string.c @@ -603,10 +603,12 @@ static int left_number_strcmp(const char *s1, const char *s2, int *tiebreaker) int numdigit, numzero1, numzero2; /* count and skip leading zeros */ - for (numzero1 = 0; *p1 && (*p1 == '0'); numzero1++) + for (numzero1 = 0; *p1 == '0'; numzero1++) { p1++; - for (numzero2 = 0; *p2 && (*p2 == '0'); numzero2++) + } + for (numzero2 = 0; *p2 == '0'; numzero2++) { p2++; + } /* find number of consecutive digits */ for (numdigit = 0; ; numdigit++) { |