summaryrefslogtreecommitdiff
path: root/include/ZeroTierOne.h
diff options
context:
space:
mode:
authorAdam Ierymenko <adam.ierymenko@gmail.com>2016-01-12 11:34:22 -0800
committerAdam Ierymenko <adam.ierymenko@gmail.com>2016-01-12 11:34:22 -0800
commitd6f0f1a82ad78c033d2a772b3a1655b9c6c48e3c (patch)
tree410470d599f8043e9aefa1c39a45935f584dd6ec /include/ZeroTierOne.h
parent83ef98a9dc4fb3c40a15a7fe2b5642355e4c4142 (diff)
downloadinfinitytier-d6f0f1a82ad78c033d2a772b3a1655b9c6c48e3c.tar.gz
infinitytier-d6f0f1a82ad78c033d2a772b3a1655b9c6c48e3c.zip
Use network user ptr in lookup for Ethernet frame handling to eliminate map lookup.
Diffstat (limited to 'include/ZeroTierOne.h')
-rw-r--r--include/ZeroTierOne.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/ZeroTierOne.h b/include/ZeroTierOne.h
index e10b2c04..cfbecf16 100644
--- a/include/ZeroTierOne.h
+++ b/include/ZeroTierOne.h
@@ -981,7 +981,7 @@ typedef int (*ZT_VirtualNetworkConfigFunction)(
ZT_Node *, /* Node */
void *, /* User ptr */
uint64_t, /* Network ID */
- void *, /* Network user ptr (set w/join) */
+ void **, /* Modifiable network user PTR */
enum ZT_VirtualNetworkConfigOperation, /* Config operation */
const ZT_VirtualNetworkConfig *); /* Network configuration */
@@ -996,7 +996,7 @@ typedef void (*ZT_VirtualNetworkFrameFunction)(
ZT_Node *, /* Node */
void *, /* User ptr */
uint64_t, /* Network ID */
- void *, /* Network user PTR (set w/join) */
+ void **, /* Modifiable network user PTR */
uint64_t, /* Source MAC */
uint64_t, /* Destination MAC */
unsigned int, /* Ethernet type */
@@ -1247,10 +1247,10 @@ enum ZT_ResultCode ZT_Node_processBackgroundTasks(ZT_Node *node,uint64_t now,vol
*
* @param node Node instance
* @param nwid 64-bit ZeroTier network ID
- * @param uptr An arbitrary pointer to associate with this network
+ * @param uptr An arbitrary pointer to associate with this network (default: NULL)
* @return OK (0) or error code if a fatal error condition has occurred
*/
-enum ZT_ResultCode ZT_Node_join(ZT_Node *node,uint64_t nwid,void *uptr);
+enum ZT_ResultCode ZT_Node_join(ZT_Node *node,uint64_t nwid,void *uptr = (void *)0);
/**
* Leave a network