From 4d5dadf0b947ef9b1bde27b64ea0683576b2c2fd Mon Sep 17 00:00:00 2001 From: "kevin.larke" Date: Wed, 8 Apr 2020 20:04:14 -0400 Subject: [PATCH] cwAudioDeviceAlsa.cpp : Added pre-proc guard around SND_PCM_STATE_PRIVATE1. --- cwAudioDeviceAlsa.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/cwAudioDeviceAlsa.cpp b/cwAudioDeviceAlsa.cpp index f93c12e..612b908 100644 --- a/cwAudioDeviceAlsa.cpp +++ b/cwAudioDeviceAlsa.cpp @@ -166,7 +166,9 @@ namespace cw case SND_PCM_STATE_PAUSED: return "paused"; case SND_PCM_STATE_SUSPENDED: return "suspended"; case SND_PCM_STATE_DISCONNECTED: return "disconnected"; - //case SND_PCM_STATE_PRIVATE1: return "private1"; +#if defined(OS_64) // SND_PCM_STATE_PRIVATE1 is not defined on Rasp. Pi. which also happens to be 32bit OS. + case SND_PCM_STATE_PRIVATE1: return "private1"; +#endif } return ""; @@ -491,7 +493,9 @@ namespace cw case SND_PCM_STATE_DRAINING: case SND_PCM_STATE_PAUSED: case SND_PCM_STATE_DISCONNECTED: - //case SND_PCM_STATE_PRIVATE1: +#if defined(OS_64) // SND_PCM_STATE_PRIVATE1 is not defined on Rasp. Pi. which also happens to be 32bit OS. + case SND_PCM_STATE_PRIVATE1: +#endif //case SND_PCM_STATE_LAST: break; } @@ -872,7 +876,9 @@ namespace cw case SND_PCM_STATE_DRAINING: case SND_PCM_STATE_PAUSED: case SND_PCM_STATE_DISCONNECTED: - //case SND_PCM_STATE_PRIVATE1: +#if defined(OS_64) // SND_PCM_STATE_PRIVATE1 is not defined on Rasp. Pi. which also happens to be 32bit OS. + case SND_PCM_STATE_PRIVATE1: +#endif continue; case SND_PCM_STATE_RUNNING: