mirror of
https://code.briarproject.org/briar/briar.git
synced 2026-02-13 11:19:04 +01:00
Don't try to discover peers if discovery is already in progress.
This commit is contained in:
@@ -407,6 +407,10 @@ class AndroidBluetoothPlugin extends BluetoothPlugin<BluetoothServerSocket> {
|
||||
}
|
||||
|
||||
private List<BluetoothDevice> discoverDevices() {
|
||||
if (adapter.isDiscovering()) {
|
||||
LOG.info("Already discovering");
|
||||
return emptyList();
|
||||
}
|
||||
List<BluetoothDevice> devices = new ArrayList<>();
|
||||
BlockingQueue<Intent> intents = new LinkedBlockingQueue<>();
|
||||
QueueingReceiver receiver = new QueueingReceiver(intents);
|
||||
|
||||
Reference in New Issue
Block a user