diff --git a/lib/techniques/error/use.py b/lib/techniques/error/use.py index 86de58e4a..4ed145a55 100644 --- a/lib/techniques/error/use.py +++ b/lib/techniques/error/use.py @@ -320,8 +320,8 @@ def errorUse(expression, expected=None, resumeValue=True, dump=False): try: threadData = getCurrentThreadData() - numThreads = min(conf.threads, stopLimit-startLimit) - threadData.shared.limits = range(startLimit, stopLimit) + threadData.shared.limits = range(startLimit, stopLimit+1) + numThreads = min(conf.threads, len(threadData.shared.limits)) threadData.shared.outputs = [] if stopLimit > TURN_OFF_RESUME_INFO_LIMIT: diff --git a/lib/techniques/union/use.py b/lib/techniques/union/use.py index c3b972668..6f9af2557 100644 --- a/lib/techniques/union/use.py +++ b/lib/techniques/union/use.py @@ -261,8 +261,8 @@ def unionUse(expression, unpack=True, dump=False): try: threadData = getCurrentThreadData() - numThreads = min(conf.threads, stopLimit-startLimit) - threadData.shared.limits = range(startLimit, stopLimit) + threadData.shared.limits = range(startLimit, stopLimit+1) + numThreads = min(conf.threads, len(threadData.shared.limits)) threadData.shared.value = "" if stopLimit > TURN_OFF_RESUME_INFO_LIMIT: