Update C# example client/server application. Other minor tweaks.

This commit is contained in:
Joseph Henry
2021-01-14 22:21:06 -08:00
parent f463d6c69f
commit b907635779
2 changed files with 129 additions and 112 deletions

View File

@@ -39,7 +39,7 @@ namespace ZeroTier
static ZeroTierManagedEventCallback _managedCallback;
// Callback used internally to ferry events from the C++ layer
static void myZeroTierEventCallback(IntPtr msgPtr)
static void OnZeroTierEvent(IntPtr msgPtr)
{
// Marshal the callback message pointer to a structure that we can inspect
zts_callback_msg msg =
@@ -224,7 +224,7 @@ namespace ZeroTier
if (_hasBeenFreed == true) {
throw new ObjectDisposedException("ZeroTier Node has previously been freed. Restart application to create new instance.");
}
return zts_start(_configFilePath,myZeroTierEventCallback,_servicePort);
return zts_start(_configFilePath,OnZeroTierEvent,_servicePort);
}
/// <summary>