diff --git a/src/isinetaddr6.c b/src/isinetaddr6.c index 9cca06d..8b6e181 100644 --- a/src/isinetaddr6.c +++ b/src/isinetaddr6.c @@ -56,10 +56,9 @@ static bool has_consecutive_chars(const char *str, char c, int n) { for (int i = 0; i < n; i++) { - if (*str != c) { + if (*str++ != c) { return 0; } - str++; } return 1; }