libnm-glib: don't warn when dbus object initialization fails with UNKNOWN_METHOD

A common case where this warning was triggered, was the removal of
IP6Config objects. As this can happen as a regular event, do not warn in
this case.

Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
Thomas Haller 2013-09-05 22:07:56 +02:00
parent fa0112c0ca
commit 2766829a67

View file

@ -638,8 +638,10 @@ async_inited (GObject *source, GAsyncResult *result, gpointer user_data)
GError *error = NULL;
if (!g_async_initable_init_finish (G_ASYNC_INITABLE (object), result, &error)) {
g_warning ("Could not create object for %s: %s",
nm_object_or_connection_get_path (object), error->message);
if (!g_error_matches (error, DBUS_GERROR, DBUS_GERROR_UNKNOWN_METHOD)) {
g_warning ("Could not create object for %s: %s",
nm_object_or_connection_get_path (object), error->message);
}
g_error_free (error);
g_object_unref (object);
object = NULL;