X-Git-Url: http://git.meshlink.io/?a=blobdiff_plain;ds=sidebyside;f=src%2Fmeshlink.h;h=be929c29e23680657e14a095064ac652b22ff66e;hb=185a8731839551fc9df7059ac374be5f5e35c086;hp=30491b0016d73dab462e8e0e5bba0e32b8b14344;hpb=61d9b04f66055e61f0afdf8955ff890f4da39288;p=meshlink diff --git a/src/meshlink.h b/src/meshlink.h index 30491b00..be929c29 100644 --- a/src/meshlink.h +++ b/src/meshlink.h @@ -166,7 +166,7 @@ extern const char *meshlink_strerror(meshlink_errno_t err); * @return A pointer to a meshlink_handle_t which represents this instance of MeshLink, or NULL in case of an error. * The pointer is valid until meshlink_close() is called. */ -extern meshlink_handle_t *meshlink_open(const char *confbase, const char *name, const char* appname, dev_class_t devclass); +extern meshlink_handle_t *meshlink_open(const char *confbase, const char *name, const char *appname, dev_class_t devclass); /// Start MeshLink. /** This function causes MeshLink to open network sockets, make outgoing connections, and @@ -832,6 +832,16 @@ extern void meshlink_hint_address(meshlink_handle_t *mesh, meshlink_node_t *node */ extern meshlink_edge_t **meshlink_get_all_edges_state(meshlink_handle_t *mesh, meshlink_edge_t **edges, size_t *nmemb); +/// Enable or disable zeroconf discovery of local peers + +/** This controls whether zeroconf discovery using the Catta library will be + * enabled to search for peers on the local network. By default, it is enabled. + * + * @param mesh A handle which represents an instance of MeshLink. + * @param enable Set to true to enable discovery, false to disable. + */ +extern void meshlink_enable_discovery(meshlink_handle_t *mesh, bool enable); + #ifdef __cplusplus } #endif