From e2f7e83d25a5f0966938163c18b1fd8c399393b1 Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Thu, 3 Nov 2005 23:36:25 +0000 Subject: * allow the user to specify a static browse domain list in the configuration file * remove "drop-root" configuration variable * move the configuration variable "add-service-cookie" from [server] to [publish] * reorder AVAHI_DOMAIN_BROWSER_xx defs git-svn-id: file:///home/lennart/svn/public/avahi/trunk@926 941a03a8-eaeb-0310-b9a0-b1bbd8fe43fe --- avahi-common/defs.h | 7 ++++--- avahi-common/strlst.c | 5 ++++- 2 files changed, 8 insertions(+), 4 deletions(-) (limited to 'avahi-common') diff --git a/avahi-common/defs.h b/avahi-common/defs.h index 4393e98..8167f34 100644 --- a/avahi-common/defs.h +++ b/avahi-common/defs.h @@ -156,10 +156,10 @@ typedef enum { /** The type of domain to browse for */ typedef enum { - AVAHI_DOMAIN_BROWSER_REGISTER, /**< Browse for a list of available registering domains */ - AVAHI_DOMAIN_BROWSER_REGISTER_DEFAULT, /**< Browse for the default registering domain */ AVAHI_DOMAIN_BROWSER_BROWSE, /**< Browse for a list of available browsing domains */ AVAHI_DOMAIN_BROWSER_BROWSE_DEFAULT, /**< Browse for the default browsing domain */ + AVAHI_DOMAIN_BROWSER_REGISTER, /**< Browse for a list of available registering domains */ + AVAHI_DOMAIN_BROWSER_REGISTER_DEFAULT, /**< Browse for the default registering domain */ AVAHI_DOMAIN_BROWSER_BROWSE_LEGACY, /**< Legacy browse domain - see DNS-SD spec for more information */ AVAHI_DOMAIN_BROWSER_MAX } AvahiDomainBrowserType; @@ -189,7 +189,8 @@ typedef enum { AVAHI_LOOKUP_RESULT_WIDE_AREA = 2, /**< This response originates from wide area DNS */ AVAHI_LOOKUP_RESULT_MULTICAST = 4, /**< This response originates from multicast DNS */ AVAHI_LOOKUP_RESULT_LOCAL = 8, /**< This record/service resides on and was announced by the local host. Only available in service and record browsers and only on AVAHI_BROWSER_NEW. */ - AVAHI_LOOKUP_RESULT_OUR_OWN = 16 /**< This service belongs to the same local client as the browser object. Only available in avahi-client, and only for service browsers and only on AVAHI_BROWSER_NEW. */ + AVAHI_LOOKUP_RESULT_OUR_OWN = 16, /**< This service belongs to the same local client as the browser object. Only available in avahi-client, and only for service browsers and only on AVAHI_BROWSER_NEW. */ + AVAHI_LOOKUP_RESULT_STATIC = 32 /**< The returned data has been defined statically by some configuration option */ } AvahiLookupResultFlags; /** Type of callback event when browsing */ diff --git a/avahi-common/strlst.c b/avahi-common/strlst.c index 4b96112..0111870 100644 --- a/avahi-common/strlst.c +++ b/avahi-common/strlst.c @@ -299,7 +299,10 @@ AvahiStringList *avahi_string_list_copy(const AvahiStringList *l) { AvahiStringList *r = NULL; for (; l; l = l->next) - r = avahi_string_list_add_arbitrary(r, l->text, l->size); + if (!(r = avahi_string_list_add_arbitrary(r, l->text, l->size))) { + avahi_string_list_free(r); + return NULL; + } return avahi_string_list_reverse(r); } -- cgit