X-Git-Url: http://git.meshlink.io/?p=meshlink;a=blobdiff_plain;f=src%2Fmeshlink.h;fp=src%2Fmeshlink.h;h=738f8647e5071d3ca815558d942229447fbc3884;hp=3a23eb088b6d38a810b7f821565b00cd6afdfddd;hb=c4deb6c20dceb73c0ac6baa2eb901434584e6191;hpb=77af15ef03a9777a43fc14aedd566655b1547441 diff --git a/src/meshlink.h b/src/meshlink.h index 3a23eb08..738f8647 100644 --- a/src/meshlink.h +++ b/src/meshlink.h @@ -801,6 +801,8 @@ bool meshlink_verify(struct meshlink_handle *mesh, struct meshlink_node *source, * * If a canonical Address is set for the local node, * it will be used for the hostname part of generated invitation URLs. + * If a canonical Address is set for a remote node, + * it is used exclusively for creating outgoing connections to that node. * * \memberof meshlink_node * @param mesh A handle which represents an instance of MeshLink. @@ -813,6 +815,17 @@ bool meshlink_verify(struct meshlink_handle *mesh, struct meshlink_node *source, */ bool meshlink_set_canonical_address(struct meshlink_handle *mesh, struct meshlink_node *node, const char *address, const char *port) __attribute__((__warn_unused_result__)); +/// Clear the canonical Address for a node. +/** This function clears the canonical Address for a node. + * + * \memberof meshlink_node + * @param mesh A handle which represents an instance of MeshLink. + * @param node A pointer to a struct meshlink_node describing the node. + * + * @return This function returns true if the address was removed, false otherwise. + */ +bool meshlink_clear_canonical_address(struct meshlink_handle *mesh, struct meshlink_node *node) __attribute__((__warn_unused_result__)); + /// Add an invitation address for the local node. /** This function adds an address for the local node, which will be used only for invitation URLs. * This address is not stored permanently.