Skip to content

Commit

Permalink
Fix BUG #38
Browse files Browse the repository at this point in the history
  • Loading branch information
Jbob committed May 29, 2015
1 parent 72218a0 commit 3b9cc0b
Show file tree
Hide file tree
Showing 5 changed files with 5 additions and 6 deletions.
1 change: 0 additions & 1 deletion AbstractService/AbstractService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ protected virtual void ModuleLooper()

// Once all modules have been run, sleep for the set time
var sleepTime = GetSleepTime() ?? DefaultSleepTime;
RegistryHandler.SetSystemSetting("Sleep", sleepTime.ToString());
Log.Entry(Name, string.Format("Sleeping for {0} seconds", sleepTime));
Thread.Sleep(sleepTime * 1000);
}
Expand Down
1 change: 0 additions & 1 deletion Debugger/obj/Release/Debugger.csproj.FileListAbsolute.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,3 @@ D:\fog\client\Debugger\bin\x86\Release\Handlers.dll
D:\fog\client\Debugger\bin\x86\Release\Modules.dll
D:\fog\client\Debugger\bin\x86\Release\ManagedOpenSsl.dll
D:\fog\client\Debugger\bin\x86\Release\Microsoft.Win32.TaskScheduler.dll
D:\fog\client\bin\Debugger.exe.config
6 changes: 2 additions & 4 deletions FOGService.Tests/Handlers/CommunicationTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ public void GetResponse()
Assert.AreEqual("bar", response.GetField("#Foo"));
Assert.IsEmpty(response.GetField("#Empty"));
Assert.AreEqual("Special", response.GetField("#-X"));
Assert.IsEmpty(response.GetField("#NON_EXISTENT"));
Assert.IsNull(response.GetField("#NON_EXISTENT"));
}

[Test]
Expand All @@ -105,8 +105,6 @@ public void GetRawResponse()
Assert.AreEqual(phrase, response);
}



[Test]
public void ParseResponse()
{
Expand All @@ -125,7 +123,7 @@ public void ParseResponse()
Assert.AreEqual("bar", response.GetField("#Foo"));
Assert.IsEmpty(response.GetField("#Empty"));
Assert.AreEqual("Special", response.GetField("#-X"));
Assert.IsEmpty(response.GetField("#NON_EXISTENT"));
Assert.IsNull(response.GetField("#NON_EXISTENT"));
}

[Test]
Expand Down
Binary file modified FOGService.v12.suo
Binary file not shown.
3 changes: 3 additions & 0 deletions Service/FOGSystemService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,10 @@ protected override void ModuleLooper()
{
var sleepTime = int.Parse(response.GetField("#sleep"));
if (sleepTime >= DefaultSleepTime)
{
RegistryHandler.SetSystemSetting("Sleep", sleepTime.ToString());
return sleepTime;
}

Log.Entry(Name, string.Format("Sleep time set on the server is below the minimum of {0}", DefaultSleepTime));
}
Expand Down

0 comments on commit 3b9cc0b

Please sign in to comment.