From 9a3414b847da82e8d7db0e062009826a832a5888 Mon Sep 17 00:00:00 2001 From: AlexandreRouma Date: Thu, 23 Mar 2023 23:19:05 +0100 Subject: [PATCH] Made the code more useful to the user maybe just yeeting out of the start function with no indication to the user is a bad idea? --- source_modules/limesdr_source/src/main.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source_modules/limesdr_source/src/main.cpp b/source_modules/limesdr_source/src/main.cpp index 51eded74..620d467b 100644 --- a/source_modules/limesdr_source/src/main.cpp +++ b/source_modules/limesdr_source/src/main.cpp @@ -330,7 +330,8 @@ private: if (err) { LMS_Close(_this->openDev); LMS_Open(&_this->openDev, _this->devList[_this->devId], NULL); - if (LMS_Init(_this->openDev) != 0) { + if (err = LMS_Init(_this->openDev)) { + flog::error("Failed to re-initialize device ({})", err); return; } }