From 93dcb6aefa7bd19e2bedc93dfac76d469b6934b6 Mon Sep 17 00:00:00 2001 From: Chris Cameron Date: Wed, 18 Oct 2017 13:17:38 -0400 Subject: [PATCH] Potential fix for SafeTimer.Stopped() immediately executing the callback --- ICD.Common.Utils/Timers/SafeTimer.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/ICD.Common.Utils/Timers/SafeTimer.cs b/ICD.Common.Utils/Timers/SafeTimer.cs index 1d66556..aac2320 100644 --- a/ICD.Common.Utils/Timers/SafeTimer.cs +++ b/ICD.Common.Utils/Timers/SafeTimer.cs @@ -65,7 +65,8 @@ namespace ICD.Common.Utils.Timers /// public static SafeTimer Stopped(Action callback) { - SafeTimer output = new SafeTimer(callback, 0); + // Some arbitrarily large number that shouldn't timeout before we call stop. + SafeTimer output = new SafeTimer(callback, 100 * 1000, 100 * 1000); output.Stop(); return output; }