diff options
Diffstat (limited to 'addrtostr.c')
| -rw-r--r-- | addrtostr.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/addrtostr.c b/addrtostr.c index 1fd2cf0908bf..2c4133b5be72 100644 --- a/addrtostr.c +++ b/addrtostr.c @@ -127,9 +127,11 @@ addrtostr6 (const void *src, char *dst, size_t size) cur.base = -1; for (i = 0; i < (IN6ADDRSZ / INT16SZ); i++) { if (words[i] == 0) { - if (cur.base == -1) - cur.base = i, cur.len = 1; - else cur.len++; + if (cur.base == -1) { + cur.base = i; + cur.len = 1; + } else + cur.len++; } else if (cur.base != -1) { if (best.base == -1 || cur.len > best.len) best = cur; |
