From 98842e9a211ecf16bf64f1bf2cdbc2a7f7fd5b97 Mon Sep 17 00:00:00 2001 From: Bill Somerville Date: Sun, 31 May 2015 13:39:28 +0000 Subject: [PATCH] Fix band hopping regression git-svn-id: svn+ssh://svn.code.sf.net/p/wsjt/wsjt/branches/wsjtx@5478 ab8295b8-cf94-4d9e-aec4-7959e3be5d79 --- mainwindow.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mainwindow.cpp b/mainwindow.cpp index bcfb88699..5f3057531 100644 --- a/mainwindow.cpp +++ b/mainwindow.cpp @@ -4303,9 +4303,8 @@ void MainWindow::bandHopping() } QString new_band; - int index; - if ((index = s.indexOf (hopping_bands[iband0])) >= 0) { //See if designated band is active - new_band = hopping_bands[index]; + if (s.contains (hopping_bands[iband0])) { //See if designated band is active + new_band = hopping_bands[iband0]; } else { // If designated band is not active, choose one that is active