mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2025-12-31 03:10:10 +01:00
core/ovs: don't fail with "cancelled" reason for disconnected ovsdb
API should fail with a "cancelled" error if (and only if) the user cancelled the operation. An error to communicate with OVSDB or being disconnected should fail with a different reason.
This commit is contained in:
parent
2983febf39
commit
8b4d77a453
1 changed files with 4 additions and 1 deletions
|
|
@ -2035,7 +2035,10 @@ ovsdb_disconnect(NMOvsdb *self, gboolean retry, gboolean is_disposing)
|
|||
} else {
|
||||
gs_free_error GError *error = NULL;
|
||||
|
||||
nm_utils_error_set_cancelled(&error, is_disposing, "NMOvsdb");
|
||||
if (is_disposing)
|
||||
nm_utils_error_set_cancelled(&error, is_disposing, "NMOvsdb");
|
||||
else
|
||||
nm_utils_error_set(&error, NM_UTILS_ERROR_NOT_READY, "disconnected from ovsdb");
|
||||
while ((call = c_list_last_entry(&priv->calls_lst_head, OvsdbMethodCall, calls_lst)))
|
||||
_call_complete(call, NULL, error);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue