Re: [Bluez-devel] [PATCH] Make BluetoothClient work on all adapters

Marcel Holtmann
2007-07-24T21:14:48Z

Hi Bastien,

> With this patch, we can now pass a NULL as the adapter to work with all
> the adapters. This is for use in the upcoming patch for the selector
> widget.

I don't like it. We should not wildly use all attached adapters. Passing
a NULL to the client creation should use the default adapter.

Actually in case of multiple adapters we need to provide one extra step
to let the user select the appropriate adapter.

Main reason, why I don't wanna start an inquiry on all adapters is that
it can happen that you see a remote device with one adapter, but then
the actual connection or device discovery is done via another one. That
is not good. We should always use the default adapter and if (and only
if) more adapters are present, then present a way to select a different
adapter.

However this includes that we have to monitor if the default adapter
changes or one adapter gets removed while being in the adapter selector
widget or device selector widget.