From 545523204258e73d9a966364262ce91c953e3d13 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Wed, 16 Jan 2013 15:54:26 +0200 Subject: [PATCH] tools: Fix waiting for expected events in mgmt-tester --- tools/mgmt-tester.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/tools/mgmt-tester.c b/tools/mgmt-tester.c index 7db0d4133..f0880ca65 100644 --- a/tools/mgmt-tester.c +++ b/tools/mgmt-tester.c @@ -945,15 +945,18 @@ static void command_generic_callback(uint8_t status, uint16_t length, return; } - if (test->expect_settings_set) - return; - if (test->expect_hci_command && !data->hci_commands_complete) { tester_warn("Command completed without expected HCI command"); tester_test_failed(); return; } + if (test->expect_settings_set) + return; + + if (test->expect_class_of_dev) + return; + tester_test_passed(); } -- 2.47.3