From b7bfa24f22a3a5a7709ce425ffc84bd4bb64be08 Mon Sep 17 00:00:00 2001 From: Max Kellermann Date: Mon, 2 Mar 2009 09:42:16 +0100 Subject: pcm_volume: return bool Don't abort MPD when a sample format is not supported by pcm_volume(). --- src/pcm_volume.h | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'src/pcm_volume.h') diff --git a/src/pcm_volume.h b/src/pcm_volume.h index 1b5e7fb0e..e21ea6f56 100644 --- a/src/pcm_volume.h +++ b/src/pcm_volume.h @@ -22,6 +22,7 @@ #include "pcm_prng.h" #include +#include enum { /** this value means "100% volume" */ @@ -62,8 +63,9 @@ pcm_volume_dither(void) * @param length the length of the PCM buffer * @param format the audio format of the PCM buffer * @param volume the volume between 0 and #PCM_VOLUME_1 + * @return true on success, false if the audio format is not supported */ -void +bool pcm_volume(void *buffer, int length, const struct audio_format *format, int volume); -- cgit v1.2.3