From 2c96c1f9ff37a58cd73454425ad9b4393eb28f0c Mon Sep 17 00:00:00 2001 From: marcsello Date: Wed, 21 Oct 2020 03:40:46 +0200 Subject: [PATCH] Fixed crasing on limited number of requests --- benchmark2.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/benchmark2.py b/benchmark2.py index 5bbdae1..c13d177 100644 --- a/benchmark2.py +++ b/benchmark2.py @@ -198,7 +198,8 @@ def run_benchmark( worker.terminate() # Not the nicest solution # Stop the input generator - input_generator_thread.active = False + if input_generator_thread: + input_generator_thread.active = False # read out all send requests to an array for handling later: results = {}