platform: add nm_platform_try_get() function
This commit is contained in:
@@ -124,6 +124,12 @@ nm_platform_get ()
|
|||||||
return singleton_instance;
|
return singleton_instance;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
NMPlatform *
|
||||||
|
nm_platform_try_get (void)
|
||||||
|
{
|
||||||
|
return singleton_instance;
|
||||||
|
}
|
||||||
|
|
||||||
/******************************************************************/
|
/******************************************************************/
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -490,6 +490,7 @@ GType nm_platform_get_type (void);
|
|||||||
|
|
||||||
void nm_platform_setup (NMPlatform *instance);
|
void nm_platform_setup (NMPlatform *instance);
|
||||||
NMPlatform *nm_platform_get (void);
|
NMPlatform *nm_platform_get (void);
|
||||||
|
NMPlatform *nm_platform_try_get (void);
|
||||||
|
|
||||||
#define NM_PLATFORM_GET (nm_platform_get ())
|
#define NM_PLATFORM_GET (nm_platform_get ())
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user