summary refs log tree commit diff
path: root/src/supplicant-manager
diff options
context:
space:
mode:
Diffstat (limited to 'src/supplicant-manager')
-rw-r--r--src/supplicant-manager/nm-supplicant-manager.c14
1 files changed, 1 insertions, 13 deletions
diff --git a/src/supplicant-manager/nm-supplicant-manager.c b/src/supplicant-manager/nm-supplicant-manager.c
index 6358c180..083f2ebc 100644
--- a/src/supplicant-manager/nm-supplicant-manager.c
+++ b/src/supplicant-manager/nm-supplicant-manager.c
@@ -318,19 +318,7 @@ on_proxy_acquired (GObject *object, GAsyncResult *result, gpointer user_data)
 
 /*******************************************************************/
 
-NMSupplicantManager *
-nm_supplicant_manager_get (void)
-{
-	static NMSupplicantManager *singleton = NULL;
-
-	if (!singleton)
-		singleton = NM_SUPPLICANT_MANAGER (g_object_new (NM_TYPE_SUPPLICANT_MANAGER, NULL));
-	else
-		g_object_ref (singleton);
-
-	g_assert (singleton);
-	return singleton;
-}
+NM_DEFINE_SINGLETON_GETTER (NMSupplicantManager, nm_supplicant_manager_get, NM_TYPE_SUPPLICANT_MANAGER);
 
 static void
 nm_supplicant_manager_init (NMSupplicantManager *self)