improve user experience for some users

This commit is contained in:
clowwindy
2015-08-18 04:26:11 -07:00
parent 3b90b2124f
commit 71bd0d2b5a
5 changed files with 29 additions and 8 deletions
@@ -146,7 +146,7 @@ Connection: Close
", System.Text.Encoding.UTF8.GetBytes(pac).Length) + pac;
byte[] response = System.Text.Encoding.UTF8.GetBytes(text);
socket.BeginSend(response, 0, response.Length, 0, new AsyncCallback(SendCallback), socket);
Util.Utils.ReleaseMemory();
Util.Utils.ReleaseMemory(true);
}
catch (Exception e)
{
@@ -360,7 +360,7 @@ namespace Shadowsocks.Controller
}
UpdateSystemProxy();
Util.Utils.ReleaseMemory();
Util.Utils.ReleaseMemory(true);
}
@@ -417,7 +417,7 @@ namespace Shadowsocks.Controller
{
while (true)
{
Util.Utils.ReleaseMemory();
Util.Utils.ReleaseMemory(false);
Thread.Sleep(30 * 1000);
}
}