From 3ce35500b9f3861f3aea00f2becbf3e43d861826 Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Fri, 17 Feb 2023 14:01:09 +0000 Subject: [PATCH] Fix Qt5 compile (hopefully) --- cwsidetone.cpp | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/cwsidetone.cpp b/cwsidetone.cpp index 207e680..c778e92 100644 --- a/cwsidetone.cpp +++ b/cwsidetone.cpp @@ -180,11 +180,10 @@ QByteArray cwSidetone::generateData(qint64 len, qint64 freq) { QByteArray data; + const int channels = format.channelCount(); #if (QT_VERSION < QT_VERSION_CHECK(6,0,0)) - const int channels = format.channels(); const int channelBytes = format.sampleSize() / 8; #else - const int channels = format.channelCount(); const int channelBytes = format.bytesPerSample(); #endif