Logo Search packages:      
Sourcecode: avahi version File versions  Download package

int avahi_server_add_service ( AvahiServer s,
AvahiSEntryGroup g,
AvahiIfIndex  interface,
AvahiProtocol  protocol,
AvahiPublishFlags  flags,
const char *  name,
const char *  type,
const char *  domain,
const char *  host,
uint16_t  port,
  ... 
)

Add an DNS-SD service to the Server. This will add all required RRs to the server. See avahi_server_add() for more information. If adding one of the RRs fails, the function returns with an error, but it is not defined if the other RR is deleted from the server or not. Therefore, you have to free the AvahiSEntryGroup and create a new one before proceeding.

Parameters:
name  Service name, e.g. "Lennart's Files"
type  DNS-SD type, e.g. "_http._tcp"
host  Host name where this servcie resides, or NULL if on the local host
port  Port number of the service

Definition at line 709 of file entry.c.

         {

    va_list va;
    int ret;

    va_start(va, port);
    ret = server_add_service_strlst_nocopy(s, g, interface, protocol, flags, name, type, domain, host, port, avahi_string_list_new_va(va));
    va_end(va);

    return ret;
}


Generated by  Doxygen 1.6.0   Back to index