# HG changeset patch
# User StephaneLenclud
# Date 1472547880 -7200
# Node ID 74a66917910ad389cbc73f8151b6d9498b45a91a
# Parent e237c2e3354527241af76e4f41aed48ff594f3b9
Published v1.1.1.0
Fixing Harmony client reconnection to prevent exceptions.
diff -r e237c2e33545 -r 74a66917910a Server/FormMain.cs
--- a/Server/FormMain.cs Tue Aug 30 03:45:45 2016 +0200
+++ b/Server/FormMain.cs Tue Aug 30 11:04:40 2016 +0200
@@ -2989,7 +2989,7 @@
{
//Try reconnect then
#pragma warning disable CS4014 // Because this call is not awaited, execution of the current method continues before the call is completed
- ResetHarmonyAsync();
+ BeginInvoke(new MethodInvoker(delegate () { ResetHarmonyAsync(); }));
#pragma warning restore CS4014 // Because this call is not awaited, execution of the current method continues before the call is completed
}
@@ -3010,7 +3010,8 @@
Trace.WriteLine("Harmony: Connecting... ");
//First create our client and login
- Program.HarmonyClient = new HarmonyHub.Client(iTextBoxHarmonyHubAddress.Text);
+ //Tip: Set keep-alive to false when testing reconnection process
+ Program.HarmonyClient = new HarmonyHub.Client(iTextBoxHarmonyHubAddress.Text, true);
Program.HarmonyClient.OnConnectionClosedByServer += HarmonyConnectionClosedByServer;
if (File.Exists("SessionToken") && !aForceAuth)
diff -r e237c2e33545 -r 74a66917910a Server/SharpDisplayManager.csproj
--- a/Server/SharpDisplayManager.csproj Tue Aug 30 03:45:45 2016 +0200
+++ b/Server/SharpDisplayManager.csproj Tue Aug 30 11:04:40 2016 +0200
@@ -34,7 +34,7 @@
index.htm
false
0
- 1.1.0.0
+ 1.1.1.0
false
true
true
@@ -112,7 +112,7 @@
True
- ..\packages\SharpLibHarmony.0.6.2\lib\net451\HarmonyHub.dll
+ ..\packages\SharpLibHarmony.0.6.3\lib\net451\HarmonyHub.dll
True
diff -r e237c2e33545 -r 74a66917910a Server/packages.config
--- a/Server/packages.config Tue Aug 30 03:45:45 2016 +0200
+++ b/Server/packages.config Tue Aug 30 11:04:40 2016 +0200
@@ -4,7 +4,7 @@
-
+