diff --git a/openrtx/src/protocols/M17/M17Demodulator.cpp b/openrtx/src/protocols/M17/M17Demodulator.cpp index 8cbe6f8d..66b839d5 100644 --- a/openrtx/src/protocols/M17/M17Demodulator.cpp +++ b/openrtx/src/protocols/M17/M17Demodulator.cpp @@ -189,6 +189,7 @@ void M17Demodulator::init() void M17Demodulator::terminate() { // Ensure proper termination of baseband sampling + audioPath_release(basebandPath); inputStream_stop(basebandId); // Delete the buffers and deallocate memory. diff --git a/openrtx/src/protocols/M17/M17Modulator.cpp b/openrtx/src/protocols/M17/M17Modulator.cpp index a1362c75..39252acf 100644 --- a/openrtx/src/protocols/M17/M17Modulator.cpp +++ b/openrtx/src/protocols/M17/M17Modulator.cpp @@ -67,6 +67,9 @@ void M17Modulator::terminate() txRunning = false; } + // Always ensure that outgoing audio path is closed + audioPath_release(outPath); + // Deallocate memory. baseband_buffer.reset(); }