From e798d6eb602f96829bdaefee1a0141c56b33be5e Mon Sep 17 00:00:00 2001 From: Cyberboss Date: Fri, 28 Sep 2018 10:32:54 -0400 Subject: [PATCH] Ensure blocking garbage collection with host watchdog --- src/Tgstation.Server.Host.Watchdog/Watchdog.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Tgstation.Server.Host.Watchdog/Watchdog.cs b/src/Tgstation.Server.Host.Watchdog/Watchdog.cs index e03061afc7..1dbc341140 100644 --- a/src/Tgstation.Server.Host.Watchdog/Watchdog.cs +++ b/src/Tgstation.Server.Host.Watchdog/Watchdog.cs @@ -228,7 +228,7 @@ namespace Tgstation.Server.Host.Watchdog if (isWindows) { //windows dick sucking resource unlocking - GC.Collect(); + GC.Collect(Int32.MaxValue, GCCollectionMode.Default, true); await Task.Delay(TimeSpan.FromSeconds(5), cancellationToken).ConfigureAwait(false); } var tempPath = Path.Combine(assemblyStoragePath, Guid.NewGuid().ToString());