From c6b01b7e9f4126af9c48f6ac63fdbf775a3335a4 Mon Sep 17 00:00:00 2001 From: Sylvain Fasel Date: Wed, 24 Jan 2024 18:43:31 +0100 Subject: [PATCH] tests/stress_mt: ignore errors in threads for checking device counts This fixes an issue where an error that occurred in thread #X will create a false error message stating that thread #X+1 did not discover the correct number of devices --- tests/stress_mt.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/stress_mt.c b/tests/stress_mt.c index 3a8f3216b..d0716ff2d 100644 --- a/tests/stress_mt.c +++ b/tests/stress_mt.c @@ -228,7 +228,8 @@ static int test_multi_init(int enumerate) tinfo[t].number, tinfo[t].iteration, libusb_error_name(tinfo[t].err)); - } else if (enumerate) { + } + if (enumerate) { if (t > 0 && tinfo[t].devcount != last_devcount) { devcount_mismatch++; printf("Device count mismatch: Thread %d discovered %ld devices instead of %ld\n",