Make server interruptible
Use an interruptor to immediately wake up blocking calls on server_stop().
This commit is contained in:
@@ -10,6 +10,7 @@
|
||||
#include "adb.h"
|
||||
#include "coords.h"
|
||||
#include "options.h"
|
||||
#include "util/intr.h"
|
||||
#include "util/log.h"
|
||||
#include "util/net.h"
|
||||
#include "util/thread.h"
|
||||
@@ -50,6 +51,8 @@ struct server {
|
||||
sc_cond cond_stopped;
|
||||
bool stopped;
|
||||
|
||||
struct sc_intr intr;
|
||||
|
||||
sc_socket server_socket; // only used if !tunnel_forward
|
||||
sc_socket video_socket;
|
||||
sc_socket control_socket;
|
||||
|
||||
Reference in New Issue
Block a user