aboutsummaryrefslogtreecommitdiff
path: root/audio
diff options
context:
space:
mode:
authorVolker RĂ¼melin <vr_qemu@t-online.de>2021-05-17 21:46:01 +0200
committerGerd Hoffmann <kraxel@redhat.com>2021-06-17 11:54:09 +0200
commit243011896ad2503e515b4fed746402e651b8e520 (patch)
treea2ec1265cb12158f6fc0211cfe782febacc74006 /audio
parent38848ce565849e5b867a5e08022b3c755039c11a (diff)
alsaaudio: remove #ifdef DEBUG to avoid bit rot
Merge the #ifdef DEBUG code with the if statement a few lines above to avoid bit rot. Suggested-by: Gerd Hoffmann <kraxel@redhat.com> Signed-off-by: Volker RĂ¼melin <vr_qemu@t-online.de> Message-Id: <20210517194604.2545-1-vr_qemu@t-online.de> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'audio')
-rw-r--r--audio/alsaaudio.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/audio/alsaaudio.c b/audio/alsaaudio.c
index fcc2f62864..2b9789e647 100644
--- a/audio/alsaaudio.c
+++ b/audio/alsaaudio.c
@@ -34,6 +34,8 @@
#define AUDIO_CAP "alsa"
#include "audio_int.h"
+#define DEBUG_ALSA 0
+
struct pollhlp {
snd_pcm_t *handle;
struct pollfd *pfds;
@@ -587,16 +589,12 @@ static int alsa_open(bool in, struct alsa_params_req *req,
*handlep = handle;
- if (obtfmt != req->fmt ||
- obt->nchannels != req->nchannels ||
- obt->freq != req->freq) {
+ if (DEBUG_ALSA || obtfmt != req->fmt ||
+ obt->nchannels != req->nchannels || obt->freq != req->freq) {
dolog ("Audio parameters for %s\n", typ);
alsa_dump_info(req, obt, obtfmt, apdo);
}
-#ifdef DEBUG
- alsa_dump_info(req, obt, obtfmt, apdo);
-#endif
return 0;
err: