aboutsummaryrefslogtreecommitdiff
path: root/src/test/test_workqueue.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/test_workqueue.c')
-rw-r--r--src/test/test_workqueue.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/test/test_workqueue.c b/src/test/test_workqueue.c
index edefb292c0..24d7ffefa3 100644
--- a/src/test/test_workqueue.c
+++ b/src/test/test_workqueue.c
@@ -353,6 +353,7 @@ main(int argc, char **argv)
return 1;
}
}
+
if (opt_n_threads < 1 ||
opt_n_items < 1 || opt_n_inflight < 1 || opt_n_lowwater < 0 ||
opt_n_cancel > opt_n_inflight || opt_n_inflight > MAX_INFLIGHT ||
@@ -361,6 +362,10 @@ main(int argc, char **argv)
return 1;
}
+ if (opt_n_inflight > opt_n_items) {
+ opt_n_inflight = opt_n_items;
+ }
+
init_logging(1);
crypto_global_init(1, NULL, NULL);
crypto_seed_rng();