1 From 02803f510bae37eac88b0168ff887bdf7d71a7f0 Mon Sep 17 00:00:00 2001
2 From: James Woglom <j@wogloms.net>
3 Date: Wed, 1 May 2024 00:36:14 -0400
4 Subject: [PATCH] Fix build when run on pre-macOS Monterey
7 audio_switch.c | 4 ++++
8 1 file changed, 4 insertions(+)
10 diff --git a/audio_switch.c b/audio_switch.c
11 index 814edce..a064c3e 100644
14 @@ -715,7 +715,11 @@ OSStatus setMute(ASDeviceType typeRequested, ASMuteType muteRequested) {
15 AudioObjectPropertyAddress propertyAddress = {
16 .mSelector = kAudioDevicePropertyMute,
18 + #ifndef MAC_OS_VERSION_12_0
19 + .mElement = kAudioObjectPropertyElementMaster,
21 .mElement = kAudioObjectPropertyElementMain,
25 UInt32 muted = (UInt32)muteRequested;