summaryrefslogtreecommitdiffstats
path: root/avahi-common
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2005-09-26 00:07:05 +0000
committerLennart Poettering <lennart@poettering.net>2005-09-26 00:07:05 +0000
commit8782ae678cf60713b5513016f16b039251c40870 (patch)
treece1057e89d56ac38acd3350af8041e9940599133 /avahi-common
parentb2839754a3d1e15a3009561e69b41608014af0cb (diff)
* rename some DBUS errrors
* add new VERSION_MISMATCH error git-svn-id: file:///home/lennart/svn/public/avahi/trunk@630 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
Diffstat (limited to 'avahi-common')
-rw-r--r--avahi-common/dbus.c3
-rw-r--r--avahi-common/dbus.h9
-rw-r--r--avahi-common/error.c3
-rw-r--r--avahi-common/error.h3
4 files changed, 11 insertions, 7 deletions
diff --git a/avahi-common/dbus.c b/avahi-common/dbus.c
index 28428ed..14d1b2b 100644
--- a/avahi-common/dbus.c
+++ b/avahi-common/dbus.c
@@ -62,7 +62,8 @@ static const char * const table[- AVAHI_ERR_MAX] = {
AVAHI_DBUS_ERR_INVALID_PROTOCOL,
AVAHI_DBUS_ERR_INVALID_FLAGS,
AVAHI_DBUS_ERR_NOT_FOUND,
- AVAHI_DBUS_ERR_INVALID_CONFIG
+ AVAHI_DBUS_ERR_INVALID_CONFIG,
+ AVAHI_DBUS_ERR_VERSION_MISMATCH
};
int avahi_error_dbus_to_number(const char *s) {
diff --git a/avahi-common/dbus.h b/avahi-common/dbus.h
index cd90af1..5f2acff 100644
--- a/avahi-common/dbus.h
+++ b/avahi-common/dbus.h
@@ -69,10 +69,11 @@ AVAHI_C_DECL_BEGIN
#define AVAHI_DBUS_ERR_INVALID_OBJECT "org.freedesktop.Avahi.InvalidObjectError"
#define AVAHI_DBUS_ERR_NO_DAEMON "org.freedesktop.Avahi.NoDaemonError"
#define AVAHI_DBUS_ERR_INVALID_INTERFACE "org.freedesktop.Avahi.InvalidInterfaceError"
-#define AVAHI_DBUS_ERR_INVALID_PROTOCOL "org.freedesktop.Avahi.InvalidInterfaceProtocol"
-#define AVAHI_DBUS_ERR_INVALID_FLAGS "org.freedesktop.Avahi.InvalidFlags"
-#define AVAHI_DBUS_ERR_NOT_FOUND "org.freedesktop.Avahi.NotFound"
-#define AVAHI_DBUS_ERR_INVALID_CONFIG "org.freedesktop.Avahi.InvalidConfiguration"
+#define AVAHI_DBUS_ERR_INVALID_PROTOCOL "org.freedesktop.Avahi.InvalidInterfaceProtocolError"
+#define AVAHI_DBUS_ERR_INVALID_FLAGS "org.freedesktop.Avahi.InvalidFlagsError"
+#define AVAHI_DBUS_ERR_NOT_FOUND "org.freedesktop.Avahi.NotFoundError"
+#define AVAHI_DBUS_ERR_INVALID_CONFIG "org.freedesktop.Avahi.InvalidConfigurationError"
+#define AVAHI_DBUS_ERR_VERSION_MISMATCH "org.freedesktop.Avahi.VersionMismatchError"
/** Convert a DBus error string into an Avahi error number */
int avahi_error_dbus_to_number(const char *s);
diff --git a/avahi-common/error.c b/avahi-common/error.c
index 73f13d2..4242361 100644
--- a/avahi-common/error.c
+++ b/avahi-common/error.c
@@ -59,7 +59,8 @@ const char *avahi_strerror(int error) {
"Invalid protocol specification",
"Invalid flags",
"Not found",
- "Invalid configuration"
+ "Invalid configuration",
+ "Version mismatch"
};
if (-error < 0 || -error >= -AVAHI_ERR_MAX)
diff --git a/avahi-common/error.h b/avahi-common/error.h
index 2b06c5a..851c600 100644
--- a/avahi-common/error.h
+++ b/avahi-common/error.h
@@ -64,6 +64,7 @@ enum {
AVAHI_ERR_INVALID_FLAGS = -29, /**< Invalid flags */
AVAHI_ERR_NOT_FOUND = -30, /**< Not found */
AVAHI_ERR_INVALID_CONFIG = -31, /**< Configuration error */
+ AVAHI_ERR_VERSION_MISMATCH = -32, /**< Verson mismatch */
/****
**** IF YOU ADD A NEW ERROR CODE HERE, PLEASE DON'T FORGET TO ADD
@@ -73,7 +74,7 @@ enum {
**** Also remember to update the MAX value below.
****/
- AVAHI_ERR_MAX = -32
+ AVAHI_ERR_MAX = -33
};
/** Return a human readable error string for the specified error code */