summaryrefslogtreecommitdiffstats
path: root/avahi-client
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2005-11-13 16:36:33 +0000
committerLennart Poettering <lennart@poettering.net>2005-11-13 16:36:33 +0000
commitda75d1898a45c106a994cd87f8da5b6bcb2b6450 (patch)
tree2c0016b9908d4f3816e3c5ee609a12292423293a /avahi-client
parentc9d4620346b561e7eac4c04c070351710f195acc (diff)
* Make "NameAcquired" warning line disappear in avahi-client
Scheduler tweaks: * Add some more comments * Remove scheduled queries from the query queue if the querier which issued them dies. This reduces traffic immensly when many short lived queries are made, e.g. during host name lookups. * Don't free a querier object immediately when it is no longer referenced. Instead keep it and try to recycle it in case someone else wants to do the same query later on. Free it at the latest moment possible: just before the next query is scheduled to be made. This reduces traffic immensly when many short lived queries are made. With these two changes we can minimize the traffic to zero or near zero for many simple lookups. * When responding records with the FLUSH_CACHE bit set, reply immediately only when all response record have this bit set. Prior to this change we replied imediately as soon as one record hat this bit set. This change should make us pass *all* Bonjour mDNS conformance tests without any exceptions. git-svn-id: file:///home/lennart/svn/public/avahi/trunk@954 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe
Diffstat (limited to 'avahi-client')
-rw-r--r--avahi-client/client.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/avahi-client/client.c b/avahi-client/client.c
index 1067456..2fd5123 100644
--- a/avahi-client/client.c
+++ b/avahi-client/client.c
@@ -115,7 +115,11 @@ static DBusHandlerResult filter_func(DBusConnection *bus, DBusMessage *message,
avahi_client_set_errno(client, AVAHI_ERR_DISCONNECTED);
goto fail;
- } if (dbus_message_is_signal(message, DBUS_INTERFACE_DBUS, "NameOwnerChanged")) {
+ } else if (dbus_message_is_signal(message, DBUS_INTERFACE_DBUS, "NameAcquired")) {
+
+ /* Ignore this message */
+
+ } else if (dbus_message_is_signal(message, DBUS_INTERFACE_DBUS, "NameOwnerChanged")) {
char *name, *old, *new;
if (!dbus_message_get_args(
@@ -154,7 +158,7 @@ static DBusHandlerResult filter_func(DBusConnection *bus, DBusMessage *message,
} else if (!avahi_client_is_connected(client)) {
- /* Ignore messages, we get in unconnected state */
+ /* Ignore messages we get in unconnected state */
} else if (dbus_message_is_signal (message, AVAHI_DBUS_INTERFACE_SERVER, "StateChanged")) {
int32_t state;