From 5b7503e95eb9d84935efea708b9dc326ef14d8ce Mon Sep 17 00:00:00 2001 From: Thomas Graf Date: Mon, 5 Dec 2011 12:27:47 +0100 Subject: core: use nm_connection_get_setting_() whenever possible Leads to shorter, easier to read code and improves type casting safety. Signed-off-by: Thomas Graf --- examples/C/glib/list-connections-libnm-glib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'examples') diff --git a/examples/C/glib/list-connections-libnm-glib.c b/examples/C/glib/list-connections-libnm-glib.c index edb5ccc34b..01a9f254e1 100644 --- a/examples/C/glib/list-connections-libnm-glib.c +++ b/examples/C/glib/list-connections-libnm-glib.c @@ -76,7 +76,7 @@ show_connection (NMConnection *data, gpointer user_data) char timestamp_real_str[64]; const char *val1, *val2, *val3, *val4, *val5; - s_con = (NMSettingConnection *) nm_connection_get_setting (connection, NM_TYPE_SETTING_CONNECTION); + s_con = nm_connection_get_setting_connection (connection); if (s_con) { /* Get various info from NMSettingConnection and show it */ timestamp = nm_setting_connection_get_timestamp (s_con); -- cgit v1.2.1