From 96c5bd089fcde9f5150c52346e45e62e5aba2d37 Mon Sep 17 00:00:00 2001 From: Tim Gromeyer Date: Wed, 26 Mar 2025 21:55:43 +0100 Subject: [PATCH] [Linux] Fix noise controll switches multiple times --- linux/main.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/linux/main.cpp b/linux/main.cpp index 7d50774..bfceb8f 100644 --- a/linux/main.cpp +++ b/linux/main.cpp @@ -225,6 +225,11 @@ public slots: void setNoiseControlMode(NoiseControlMode mode) { LOG_INFO("Setting noise control mode to: " << mode); + if (m_noiseControlMode == mode) + { + LOG_INFO("Noise control mode is already " << mode); + return; + } QByteArray packet = AirPodsPackets::NoiseControl::getPacketForMode(mode); writePacketToSocket(packet, "Noise control mode packet written: "); }