mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-25 16:30:07 +01:00
platform: delay destruction of NMPlatform singleton until NMConfig gets destroyed
We want to create the platform instance rather late (especially after claiming the D-Bus service). But we also want to destroy it very late, because NMPlatform does not make use of any other singletons, but other singletons make use of NMPlatform.
This commit is contained in:
parent
67bcaca75e
commit
99ad9fedf5
1 changed files with 1 additions and 5 deletions
|
|
@ -420,11 +420,7 @@ main (int argc, char *argv[])
|
|||
/* Set up platform interaction layer */
|
||||
nm_linux_platform_setup ();
|
||||
|
||||
/* FIXME: intentionally leak the singleton instance of NMPlatform.
|
||||
* nm_linux_platform_setup() will register the singleton for destruction,
|
||||
* but we don't yet shut down all singletons properly, so don't destroy
|
||||
* NMPlatform. */
|
||||
g_object_ref (NM_PLATFORM_GET);
|
||||
NM_UTILS_KEEP_ALIVE (config, NM_PLATFORM_GET, "NMConfig-depends-on-NMPlatform");
|
||||
|
||||
nm_dispatcher_init ();
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue