aboutsummaryrefslogtreecommitdiffstats
path: root/src/audio.c
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/audio.c27
1 files changed, 13 insertions, 14 deletions
diff --git a/src/audio.c b/src/audio.c
index 605bf796e..a03872709 100644
--- a/src/audio.c
+++ b/src/audio.c
@@ -250,6 +250,19 @@ int openAudioDevice(AudioFormat * audioFormat) {
return 0;
}
+void audioError() {
+#ifdef HAVE_AUDIO
+ if(errno==AO_ENOTLIVE) {
+ ERROR("not a live ao device\n");
+ }
+ else if(errno==AO_EOPENDEVICE) {
+ ERROR("not able to open audio device\n");
+ }
+ else if(errno==AO_EBADOPTION) {
+ ERROR("bad driver option\n");
+ }
+#endif
+}
int playAudio(char * playChunk, int size) {
#ifdef HAVE_AUDIO
@@ -293,17 +306,3 @@ void closeAudioDevice() {
}
#endif
}
-
-void audioError() {
-#ifdef HAVE_AUDIO
- if(errno==AO_ENOTLIVE) {
- ERROR("not a live ao device\n");
- }
- else if(errno==AO_EOPENDEVICE) {
- ERROR("not able to open audio device\n");
- }
- else if(errno==AO_EBADOPTION) {
- ERROR("bad driver option\n");
- }
-#endif
-}