diff options
Diffstat (limited to 'examples/java/HelloTinyB.java')
-rw-r--r-- | examples/java/HelloTinyB.java | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/java/HelloTinyB.java b/examples/java/HelloTinyB.java index 64725b9d..b3d2c934 100644 --- a/examples/java/HelloTinyB.java +++ b/examples/java/HelloTinyB.java @@ -120,7 +120,11 @@ public class HelloTinyB { /* * After we find the device we can stop looking for other devices. */ - manager.stopDiscovery(); + try { + manager.stopDiscovery(); + } catch (BluetoothException e) { + System.err.println("Discovery could not be stopped."); + } if (sensor == null) { System.err.println("No sensor found with the provided address."); |