mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2024-11-10 04:37:37 +01:00
Fix crash in LimeSDR start when the device is disconnected
This fixes crash when a device which was enumerated on the application startup gets disconnected prior to the attempt to start the radio. The check is done after the existing work around for the LimeSuite bug. The idea is to give it the best possible chance for the radio to start. Possibly, the check needs needs to happen in the second LMS_Open() but ideally this needs to be verified against the original workaround scenario.
This commit is contained in:
parent
ec4dc6cc9e
commit
90c26f8c1b
@ -330,7 +330,9 @@ private:
|
||||
if (err) {
|
||||
LMS_Close(_this->openDev);
|
||||
LMS_Open(&_this->openDev, _this->devList[_this->devId], NULL);
|
||||
LMS_Init(_this->openDev);
|
||||
if (LMS_Init(_this->openDev) != 0) {
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
flog::warn("Channel count: {0}", LMS_GetNumChannels(_this->openDev, false));
|
||||
|
Loading…
Reference in New Issue
Block a user