aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2009-05-28 23:39:51 +0200
committerMax Kellermann <max@duempel.org>2009-05-28 23:39:51 +0200
commit535da8b7977d26f24633ddd42acbb05ad3cc8512 (patch)
treec6b9d31c1cb15ac80c40fd7508a191a0b95f360e /src
parenteb71b5b8a4a7858553604fa63da941a93fbd9370 (diff)
downloadmpd-535da8b7977d26f24633ddd42acbb05ad3cc8512.tar.gz
mpd-535da8b7977d26f24633ddd42acbb05ad3cc8512.tar.xz
mpd-535da8b7977d26f24633ddd42acbb05ad3cc8512.zip
volume: changed "default" to "DISABLED" in switch statement
Make gcc warn us if we add a new mixer type, and forget to add a new "case" line.
Diffstat (limited to '')
-rw-r--r--src/volume.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/volume.c b/src/volume.c
index 3df57ad46..9b1032294 100644
--- a/src/volume.c
+++ b/src/volume.c
@@ -190,9 +190,12 @@ int volume_level_get(void)
return software_volume_get();
case VOLUME_MIXER_TYPE_HARDWARE:
return hardware_volume_get();
- default:
+ case VOLUME_MIXER_TYPE_DISABLED:
return -1;
}
+
+ /* unreachable */
+ assert(false);
return -1;
}