tking / JSTUN

JSTUN
MIT License
133 stars 55 forks source link

It should be possible to stop the StunServer #8

Closed guusdk closed 7 years ago

guusdk commented 7 years ago

The commit adds a flag that will allow the StunServer to gracefully shut down. Additionally, it introduces a timeout that applies to data receival. When no data is received within the timeout, the newly added flag is evaluated, after which the socket attempts to receive data again.

This is a fix for https://github.com/tking/JSTUN/issues/6