connectivity: remove unused error varialbe in _idle_cb()

(cherry picked from commit 4001aee370)
(cherry picked from commit 28540a8eb8)
This commit is contained in:
Thomas Haller 2019-06-18 09:25:32 +02:00 committed by Beniamino Galvani
parent 97d3d27591
commit 597b8da697

View file

@ -662,19 +662,11 @@ _idle_cb (gpointer user_data)
cb_data->timeout_id = 0;
if (!cb_data->ifspec) {
gs_free_error GError *error = NULL;
/* the invocation was with an invalid ifname. It is a fail. */
g_set_error (&error, NM_UTILS_ERROR, NM_UTILS_ERROR_INVALID_ARGUMENT,
"no interface specified for connectivity check");
cb_data_complete (cb_data, NM_CONNECTIVITY_ERROR, "missing interface");
} else if (cb_data->fail_reason_no_dbus_connection) {
gs_free_error GError *error = NULL;
g_set_error (&error, NM_UTILS_ERROR, NM_UTILS_ERROR_INVALID_ARGUMENT,
"no D-Bus connection");
} else if (cb_data->fail_reason_no_dbus_connection)
cb_data_complete (cb_data, NM_CONNECTIVITY_ERROR, "no D-Bus connection");
} else if (cb_data->completed_reason)
else if (cb_data->completed_reason)
cb_data_complete (cb_data, cb_data->completed_state, cb_data->completed_reason);
else
cb_data_complete (cb_data, NM_CONNECTIVITY_FAKE, "fake result");