[android-developers] Re: Bluetooth chat bug?
Hi,
And by that logic device might be null as well...
Maybe check the source code.
Regards
On Jul 7, 5:12 am, bob <b...@coolfone.comze.com> wrote:
> I'm looking at the Bluetooth chat example:
>
> // When discovery finds a device
> if (BluetoothDevice.ACTION_FOUND.equals(action)) {
> // Get the BluetoothDevice object from the Intent
> BluetoothDevice device =
> intent.getParcelableExtra(BluetoothDevice.EXTRA_DEVICE);
> // If it's already paired, skip it, because it's been
> listed already
> if (device.getBondState() != BluetoothDevice.BOND_BONDED) {
> mNewDevicesArrayAdapter.add(device.getName() + "\n" +
> device.getAddress());
> }
> // When discovery is finished, change the Activity title
> }
>
> I think there is a bug here because it assumes device.getName() does not
> return null, when in fact it might.
>
> What do you guys think?
--
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscribe@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en
0 Comments:
Post a Comment
Subscribe to Post Comments [Atom]
<< Home