From cbf5e3e04454a609b8c8ab859f8612b6ec428a62 Mon Sep 17 00:00:00 2001 From: Arkadiusz Bokowy Date: Tue, 18 Apr 2023 10:51:50 +0200 Subject: [PATCH] Fix TestDnssd exit after last HandleResolved call --- src/platform/tests/TestDnssd.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/platform/tests/TestDnssd.cpp b/src/platform/tests/TestDnssd.cpp index 4a0437ce35bfb6..71540355d32355 100644 --- a/src/platform/tests/TestDnssd.cpp +++ b/src/platform/tests/TestDnssd.cpp @@ -39,9 +39,9 @@ static void HandleResolve(void * context, DnssdService * result, const chip::Spa if (gBrowsedServicesCount == ++gResolvedServicesCount) { + // After last service is resolved, stop the event loop, + // so the test case can gracefully exit. chip::DeviceLayer::PlatformMgr().StopEventLoopTask(); - chip::DeviceLayer::PlatformMgr().Shutdown(); - exit(0); } }