diff --git a/src/checkother.cpp b/src/checkother.cpp index 0822cb0ff..6ae5fb0f9 100644 --- a/src/checkother.cpp +++ b/src/checkother.cpp @@ -564,7 +564,7 @@ void CheckOther::CheckVariableScope_LookupVar(const Token *tok1, const char varn { if (for_or_while && used) return; - used1 = used; + used1 |= used; used = false; } }