diff options
author | Sven Gothel <[email protected]> | 2022-02-07 01:26:44 +0100 |
---|---|---|
committer | Sven Gothel <[email protected]> | 2022-02-07 01:26:44 +0100 |
commit | fb4af8b843bd2dd6316b20a0078117e5d199dbf9 (patch) | |
tree | 2735f7e5185cf865c58e21be872d0dc3ab3ba560 | |
parent | 7f9490c5203e638f968788cbf2b073a748556945 (diff) |
BTDevice::update(EInfoReport ..): Always update name on EIR scanned data if given
Otherwise a non removed device instance (after disconnect) would not take the (newly) discovered name.
-rw-r--r-- | src/direct_bt/BTDevice.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/direct_bt/BTDevice.cpp b/src/direct_bt/BTDevice.cpp index e2059d30..7e59515e 100644 --- a/src/direct_bt/BTDevice.cpp +++ b/src/direct_bt/BTDevice.cpp @@ -160,7 +160,7 @@ EIRDataType BTDevice::update(EInfoReport const & data) noexcept { } } if( data.isSet(EIRDataType::NAME) ) { - if( 0 == name.length() || data.getName().length() > name.length() ) { + if( data.getName().length() > 0 ) { name = data.getName(); } } |