From 7928d48257f9ea709cb94548c1cc30388d58a50a Mon Sep 17 00:00:00 2001 From: f4exb Date: Sat, 11 Mar 2023 12:42:59 +0100 Subject: [PATCH] MainWindow: disconnect prior to connect in device re-numeration. Fixes #1620 --- sdrgui/mainwindow.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sdrgui/mainwindow.cpp b/sdrgui/mainwindow.cpp index 5ade12109..16c187d94 100644 --- a/sdrgui/mainwindow.cpp +++ b/sdrgui/mainwindow.cpp @@ -1081,6 +1081,12 @@ void MainWindow::removeDeviceSet(int deviceSetIndex) DeviceGUI *deviceGUI = m_deviceUIs[i]->m_deviceGUI; Workspace *deviceWorkspace = m_workspaces[deviceGUI->getWorkspaceIndex()]; + QObject::disconnect( + deviceGUI, + &DeviceGUI::addChannelEmitted, + this, + nullptr + ); QObject::connect( deviceGUI, &DeviceGUI::addChannelEmitted,