diff options
| author | Carl Hetherington <cth@carlh.net> | 2016-07-20 10:47:49 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2016-07-20 10:47:49 +0100 |
| commit | 57d00c880094b1dfebaee18f4ecafb1dd44b0afb (patch) | |
| tree | db9d5a1bcc6be5a99afa1bd317a1c27930eaefbb /src/lib/encoder.cc | |
| parent | b34310b4e90af1442363fe09db082d68e1721130 (diff) | |
Do EncodeServerFinder 'disable' in a more sensible way.
Just stop the threads and clear the server list when
stop() is called.
Diffstat (limited to 'src/lib/encoder.cc')
| -rw-r--r-- | src/lib/encoder.cc | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/lib/encoder.cc b/src/lib/encoder.cc index 652412ddf..0c41d8d80 100644 --- a/src/lib/encoder.cc +++ b/src/lib/encoder.cc @@ -78,12 +78,10 @@ Encoder::~Encoder () void Encoder::begin () { - if (!EncodeServerFinder::instance()->disabled ()) { - weak_ptr<Encoder> wp = shared_from_this (); - _server_found_connection = EncodeServerFinder::instance()->ServersListChanged.connect ( - boost::bind (&Encoder::call_servers_list_changed, wp) - ); - } + weak_ptr<Encoder> wp = shared_from_this (); + _server_found_connection = EncodeServerFinder::instance()->ServersListChanged.connect ( + boost::bind (&Encoder::call_servers_list_changed, wp) + ); } /* We don't want the servers-list-changed callback trying to do things |
