shared: add nm_g_source_destroy_and_unref() helper

(cherry picked from commit c02710bb0f)
This commit is contained in:
Thomas Haller 2019-10-15 17:40:10 +02:00
parent c4cb3ecae7
commit d0bbd9fc0a
No known key found for this signature in database
GPG key ID: 29C2366E4DFC5728

View file

@ -918,6 +918,13 @@ nm_g_variant_unref_floating (GVariant *var)
g_variant_unref (var);
}
static inline void
nm_g_source_destroy_and_unref (GSource *source)
{
g_source_destroy (source);
g_source_unref (source);
}
/*****************************************************************************/
static inline int