libnm-core, settings: move NMSettingsError to nm-errors

Move the definition of NMSettingsError to nm-errors, register it with
D-Bus, and verify in the tests that it maps correctly.

Remove a few unused error codes, simplify a few others, and rename
GENERAL to FAILED and HOSTNAME_INVALID to INVALID_HOSTNAME, for
consistency.
This commit is contained in:
Dan Winship
2014-10-15 15:27:25 -04:00
parent 115f8bead8
commit 3be53899fa
14 changed files with 104 additions and 110 deletions

View File

@@ -30,6 +30,7 @@ G_DEFINE_QUARK (nm-connection-error-quark, nm_connection_error)
G_DEFINE_QUARK (nm-crypto-error-quark, nm_crypto_error)
G_DEFINE_QUARK (nm-device-error-quark, nm_device_error)
G_DEFINE_QUARK (nm-manager-error-quark, nm_manager_error)
G_DEFINE_QUARK (nm-settings-error-quark, nm_settings_error)
static void
register_error_domain (GQuark domain,
@@ -65,4 +66,7 @@ _nm_dbus_errors_init (void)
register_error_domain (NM_MANAGER_ERROR,
NM_DBUS_INTERFACE,
NM_TYPE_MANAGER_ERROR);
register_error_domain (NM_SETTINGS_ERROR,
NM_DBUS_INTERFACE_SETTINGS,
NM_TYPE_SETTINGS_ERROR);
}