diff src/audio/mint/SDL_mintaudio_xbios.c @ 1095:f10892fa2e48

XBIOS in interrupt not usable under MiNT
author Patrice Mandin <patmandin@gmail.com>
date Wed, 20 Jul 2005 17:39:10 +0000
parents 176240cf4405
children 76459577e620
line wrap: on
line diff
--- a/src/audio/mint/SDL_mintaudio_xbios.c	Mon Jul 18 13:42:57 2005 +0000
+++ b/src/audio/mint/SDL_mintaudio_xbios.c	Wed Jul 20 17:39:10 2005 +0000
@@ -82,8 +82,14 @@
 
 static int Audio_Available(void)
 {
+	unsigned long dummy;
 	const char *envr = getenv("SDL_AUDIODRIVER");
 
+	/* We can't use XBIOS in interrupt under MiNT */
+	if (Getcookie(C_MiNT, &dummy) == C_FOUND) {
+		return(0);
+	}
+
 	/* Check if user asked a different audio driver */
 	if ((envr) && (strcmp(envr, MINT_AUDIO_DRIVER_NAME)!=0)) {
 		DEBUG_PRINT((DEBUG_NAME "user asked a different audio driver\n"));