More Go boilerplate.
This commit is contained in:
parent
ae2120eb96
commit
ed2024285d
7 changed files with 154 additions and 11 deletions
|
@ -598,6 +598,14 @@ ZT_VirtualNetworkList *Node::networks() const
|
|||
return nl;
|
||||
}
|
||||
|
||||
void Node::setNetworkUserPtr(uint64_t nwid,void *ptr)
|
||||
{
|
||||
Mutex::Lock _l(_networks_m);
|
||||
const SharedPtr<Network> *const nw = _networks.get(nwid);
|
||||
if (nw)
|
||||
*((*nw)->userPtr()) = ptr;
|
||||
}
|
||||
|
||||
void Node::freeQueryResult(void *qr)
|
||||
{
|
||||
if (qr)
|
||||
|
@ -1011,6 +1019,13 @@ ZT_VirtualNetworkList *ZT_Node_networks(ZT_Node *node)
|
|||
}
|
||||
}
|
||||
|
||||
void ZT_Node_setNetworkUserPtr(ZT_Node *node,uint64_t nwid,void *ptr)
|
||||
{
|
||||
try {
|
||||
reinterpret_cast<ZeroTier::Node *>(node)->setNetworkUserPtr(nwid,ptr);
|
||||
} catch ( ... ) {}
|
||||
}
|
||||
|
||||
void ZT_Node_freeQueryResult(ZT_Node *node,void *qr)
|
||||
{
|
||||
try {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue