mirror of
https://github.com/AlexandreRouma/SDRPlusPlus.git
synced 2025-08-04 23:21:45 +02:00
fixed audio source crashing if no device is available
This commit is contained in:
@@ -184,6 +184,9 @@ private:
|
|||||||
AudioSourceModule* _this = (AudioSourceModule*)ctx;
|
AudioSourceModule* _this = (AudioSourceModule*)ctx;
|
||||||
if (_this->running) { return; }
|
if (_this->running) { return; }
|
||||||
|
|
||||||
|
// If no device is selected, give up
|
||||||
|
if (_this->selectedDevice.empty()) { return; }
|
||||||
|
|
||||||
// Stream options
|
// Stream options
|
||||||
RtAudio::StreamParameters parameters;
|
RtAudio::StreamParameters parameters;
|
||||||
parameters.deviceId = _this->devices[_this->devId].id;
|
parameters.deviceId = _this->devices[_this->devId].id;
|
||||||
|
Reference in New Issue
Block a user