From 189e0b3890f5a9347caea6b2249af2acfd27ccbb Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sat, 27 Jan 2018 22:05:29 +0100 Subject: [PATCH] Fix Cppcheck warning about uninitialized variable --- lib/checkbufferoverrun.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lib/checkbufferoverrun.cpp b/lib/checkbufferoverrun.cpp index 747a5847e..f23b36b33 100644 --- a/lib/checkbufferoverrun.cpp +++ b/lib/checkbufferoverrun.cpp @@ -1496,6 +1496,8 @@ void CheckBufferOverrun::bufferOverrun() } else if (tok->astOperand2()->valueType()->pointer == 0) { indexToken = tok->astOperand2(); pointerToken = tok->astOperand1(); + } else { + continue; } while (pointerToken && pointerToken->str() == ".")