From 80d6614ca71e706a373c4233d1a3b64caf6c2487 Mon Sep 17 00:00:00 2001 From: Phil Taylor Date: Sun, 16 Jul 2023 14:00:18 +0100 Subject: [PATCH] Fix compile warnings --- audioconverter.cpp | 6 +++++- rigcommander.cpp | 2 +- wfmain.cpp | 1 + 3 files changed, 7 insertions(+), 2 deletions(-) diff --git a/audioconverter.cpp b/audioconverter.cpp index 6d72532..7fee4d5 100644 --- a/audioconverter.cpp +++ b/audioconverter.cpp @@ -113,7 +113,11 @@ bool audioConverter::convert(audioPacket audio) QByteArray outPacket(nSamples * sizeof(float) * inFormat.channelCount(), (char)0xff); // Preset the output buffer size. float* out = (float*)outPacket.data(); - opus_decode_float(opusDecoder, in, audio.data.size(), out, nSamples, 0); + int ret = opus_decode_float(opusDecoder, in, audio.data.size(), out, nSamples, 0); + if (ret != nSamples) + { + qDebug(logAudio()) << "opus_decode_float: returned:" << ret << "samples, expected:" << nSamples; + } audio.data.clear(); audio.data = outPacket; // Replace incoming data with converted. } diff --git a/rigcommander.cpp b/rigcommander.cpp index b20b341..881a3ed 100644 --- a/rigcommander.cpp +++ b/rigcommander.cpp @@ -3543,7 +3543,7 @@ void rigCommander::determineRigCaps() bandType bandDef70cm = bandType(band70cm, 420000000, 450000000, modeUSB); bandType bandDef23cm = bandType(band23cm, 1240000000, 1400000000, modeUSB); bandType bandDef13cm = bandType(band13cm, 2300000000, 2450000000, modeUSB); - bandType bandDef9cm = bandType(band9cm, 3300000000, 3500000000, modeUSB); + //bandType bandDef9cm = bandType(band9cm, 3300000000, 3500000000, modeUSB); bandType bandDef6cm = bandType(band6cm, 5650000000, 5925000000, modeUSB); bandType bandDef3cm = bandType(band3cm, 10000000000, 10500000000, modeUSB); diff --git a/wfmain.cpp b/wfmain.cpp index da7cdbf..3af1e62 100644 --- a/wfmain.cpp +++ b/wfmain.cpp @@ -6290,6 +6290,7 @@ void wfmain::changeMode(mode_kind mode, bool dataOn) mode_info m; m.filter = (unsigned char) filter; m.reg = (unsigned char) mode; + m.mk = mode; issueCmd(cmdSetMode, m); currentMode = mode;