-
Notifications
You must be signed in to change notification settings - Fork 2.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Make Darwin HostNameRegistrar safer to use. (#25983)
There are two main changes here: 1) When we shut down the Matter stack, we should remove all our advertisements adn stop monitoring for network interface changes. That's what the change to ChipDnssdShutdown does. 2) It's theoretically possible for the block HostNameRegistrar passes to nw_path_monitor_set_update_handler to run after the HostNameRegistrar is destroyed. Guard against that with a shared_ptr that keeps track of the liveness state of the HostNameRegistrar. The changes to the member initialization of HostNameRegistrar are just for safety's sake, in case its destructor ever gets called without Init() having been called first. Right now that is not possible, but better to not rely on that.
- Loading branch information
1 parent
15fd339
commit 1577963
Showing
4 changed files
with
58 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters