Skip to content

Commit b7b429e

Browse files
authored
[TV Apps] Change the shutdown ordering to prevent some crashes when both commissioner and server are enabled (project-chip#35843)
1 parent fa0b299 commit b7b429e

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

examples/platform/linux/AppMain.cpp

+4-4
Original file line numberDiff line numberDiff line change
@@ -679,16 +679,16 @@ void ChipLinuxAppMainLoop(AppMainLoopImplementation * impl)
679679

680680
ApplicationShutdown();
681681

682-
#if CHIP_DEVICE_CONFIG_ENABLE_BOTH_COMMISSIONER_AND_COMMISSIONEE
683-
ShutdownCommissioner();
684-
#endif // CHIP_DEVICE_CONFIG_ENABLE_BOTH_COMMISSIONER_AND_COMMISSIONEE
685-
686682
#if defined(ENABLE_CHIP_SHELL)
687683
shellThread.join();
688684
#endif
689685

690686
Server::GetInstance().Shutdown();
691687

688+
#if CHIP_DEVICE_CONFIG_ENABLE_BOTH_COMMISSIONER_AND_COMMISSIONEE
689+
ShutdownCommissioner();
690+
#endif // CHIP_DEVICE_CONFIG_ENABLE_BOTH_COMMISSIONER_AND_COMMISSIONEE
691+
692692
#if ENABLE_TRACING
693693
tracing_setup.StopTracing();
694694
#endif

0 commit comments

Comments
 (0)