diff options
author | Sven Gothel <[email protected]> | 2020-10-14 18:51:52 +0200 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2020-10-14 18:51:52 +0200 |
commit | 822ea9aa3da8bcd9540b2cbf71c263ea521e12b4 (patch) | |
tree | f189854c65c186f259f1ee054d9e54a5441cac56 /src | |
parent | 84c3223d4ca0de21caf40b523357bf4e42b90b70 (diff) |
HCIHandler::btMode: Becomes mutable and atomic for later determination and change. Ctor uses default BTMode::NONE.
Diffstat (limited to 'src')
-rw-r--r-- | src/direct_bt/HCIHandler.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/direct_bt/HCIHandler.cpp b/src/direct_bt/HCIHandler.cpp index eb300449..81fb4636 100644 --- a/src/direct_bt/HCIHandler.cpp +++ b/src/direct_bt/HCIHandler.cpp @@ -424,13 +424,15 @@ exit: return ev; } -HCIHandler::HCIHandler(const BTMode btMode, const uint16_t dev_id) noexcept +HCIHandler::HCIHandler(const uint16_t dev_id, const BTMode btMode) noexcept : env(HCIEnv::get()), - btMode(btMode), dev_id(dev_id), rbuffer(HCI_MAX_MTU), + dev_id(dev_id), + rbuffer(HCI_MAX_MTU), comm(dev_id, HCI_CHANNEL_RAW), hciEventRing(env.HCI_EVT_RING_CAPACITY), hciReaderShallStop(false), hciReaderThreadId(0), hciReaderRunning(false), - allowClose( comm.isOpen() ) + allowClose( comm.isOpen() ), + btMode(btMode) { WORDY_PRINT("HCIHandler.ctor: pid %d", HCIHandler::pidSelf); if( !allowClose ) { |