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

int avahi_server_add ( AvahiServer s,
AvahiSEntryGroup g,
AvahiIfIndex  interface,
AvahiProtocol  protocol,
AvahiPublishFlags  flags,
AvahiRecord r 
)

Add a new resource record to the server. Returns 0 on success, negative otherwise.

Parameters:
s  The server object to add this record to
g  An entry group object if this new record shall be attached to one, or NULL. If you plan to remove the record sometime later you a required to pass an entry group object here.
interface  A numeric index of a network interface to attach this record to, or AVAHI_IF_UNSPEC to attach this record to all interfaces
protocol  A protocol family to attach this record to. One of the AVAHI_PROTO_xxx constants. Use AVAHI_PROTO_UNSPEC to make this record available on all protocols (wich means on both IPv4 and IPv6).
flags  Special flags for this record
r  The record to add. This function increases the reference counter of this object.

Definition at line 308 of file entry.c.

References AVAHI_OK, and avahi_server_errno().

                    {

    if (!server_add_internal(s, g, interface, protocol, flags, r))
        return avahi_server_errno(s);

    return AVAHI_OK;
}


Generated by  Doxygen 1.6.0   Back to index