Hand-apply 33b76b675d747fd828aba91d9d857227cb8a8244 from master; make sure signals...
[dcpomatic.git] / src / lib / encoder.cc
index 6b520571a7430efd7f9a21636cf3d8402af2f827..2a60268791134ae37d956face1349a2847f5450f 100644 (file)
@@ -93,7 +93,9 @@ Encoder::begin ()
                _threads.push_back (new boost::thread (boost::bind (&Encoder::encoder_thread, this, optional<ServerDescription> ())));
        }
 
-       ServerFinder::instance()->connect (boost::bind (&Encoder::server_found, this, _1));
+       if (!ServerFinder::instance()->disabled ()) {
+               _server_found_connection = ServerFinder::instance()->connect (boost::bind (&Encoder::server_found, this, _1));
+       }
 }
 
 void