rakijah / CSGSI

A simple C# library to interface with Counter-Strike: Global Offensive's Game State Integration
Other
129 stars 27 forks source link

Proper closing of HttpListener added. #3

Closed WoMayr closed 8 years ago

WoMayr commented 8 years ago

Before he was stuck on the waitForConnection.WaitOne(); if no additional HTTP-Request came after calling Stop(). Now the Listener gets forcefully closed and the GameStateListener stops as it is expected.

rakijah commented 8 years ago

Looks good!
The only thing I don't understand is why we are setting _Running = false; after while(_Running) has just ended (here). Seems kind of redundant to me unless there is another reason that I don't see right now.

Please explain why that line is necessary or remove it and I'll be happy to merge this.

WoMayr commented 8 years ago

Good point. Doesn't really serve any purpose at all since the loop can only be exited if _Running is already false.