From adc8ac267db28335104d37965c1762cef0a44205 Mon Sep 17 00:00:00 2001 From: Miroslav Stampar Date: Tue, 10 Mar 2015 09:23:26 +0100 Subject: [PATCH] Fixes #1190 --- lib/controller/checks.py | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/lib/controller/checks.py b/lib/controller/checks.py index e680b479a..922a413a6 100644 --- a/lib/controller/checks.py +++ b/lib/controller/checks.py @@ -719,16 +719,14 @@ def checkFalsePositives(injection): kb.injection = injection for i in xrange(conf.level): - randInt1, randInt2, randInt3 = (_() for j in xrange(3)) + while True: + randInt1, randInt2, randInt3 = (_() for j in xrange(3)) - randInt1 = min(randInt1, randInt2, randInt3) - randInt3 = max(randInt1, randInt2, randInt3) + randInt1 = min(randInt1, randInt2, randInt3) + randInt3 = max(randInt1, randInt2, randInt3) - while randInt1 >= randInt2: - randInt2 = _() - - while randInt2 >= randInt3: - randInt3 = _() + if randInt3 > randInt2 > randInt1: + break if not checkBooleanExpression("%d=%d" % (randInt1, randInt1)): retVal = None