diff options
Diffstat (limited to 'apps/ble-inspect-device.cpp')
-rw-r--r-- | apps/ble-inspect-device.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/apps/ble-inspect-device.cpp b/apps/ble-inspect-device.cpp index 2140e03..baee93a 100644 --- a/apps/ble-inspect-device.cpp +++ b/apps/ble-inspect-device.cpp @@ -29,11 +29,11 @@ public: gatt->discoverServices(); - vector<BluetoothGattService *> services = gatt->getServices(); + auto services = gatt->getServices(); cout << "Device has " << services.size() << " services" << endl; for (auto &s : services) { - const vector<BluetoothGattCharacteristic *> characteristics = s->getCharacteristics(); + auto characteristics = s->getCharacteristics(); cout << "Service: UUID: " << s->getUuid() << ", has " << characteristics.size() << " characteristics" << endl; @@ -60,10 +60,10 @@ public: scan_callback(device); return EXIT_SUCCESS; - } catch (std::runtime_error ex) { + } catch (std::runtime_error &ex) { cout << "std::runtime_error: " << ex.what() << endl; return EXIT_FAILURE; - } catch (std::exception ex) { + } catch (std::exception &ex) { cout << "std::exception: " << ex.what() << endl; return EXIT_FAILURE; } |