From 83e9ca19dfd88c6724a4b413164711613a39ef1c Mon Sep 17 00:00:00 2001 From: Nicolas Bacca Date: Fri, 28 Jan 2005 23:30:51 +0000 Subject: Fix mp3/vorbis detection svn-id: r16681 --- scumm/imuse_digi/dimuse_sndmgr.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'scumm/imuse_digi') diff --git a/scumm/imuse_digi/dimuse_sndmgr.cpp b/scumm/imuse_digi/dimuse_sndmgr.cpp index 7881e16d8d..c19fbcdefc 100644 --- a/scumm/imuse_digi/dimuse_sndmgr.cpp +++ b/scumm/imuse_digi/dimuse_sndmgr.cpp @@ -572,17 +572,17 @@ int32 ImuseDigiSndMgr::getDataFromRegion(soundStruct *soundHandle, int region, b sprintf(fileName, "%s_reg%03d.mp3", soundHandle->name, region); cmpFile = soundHandle->bundle->getFile(fileName, offs, len); #ifndef USE_MAD - if (cmpFile) + if (len) error("Mad library compiled support needed!"); #endif - if (!cmpFile) { + if (!len) { sprintf(fileName, "%s_reg%03d.ogg", soundHandle->name, region); cmpFile = soundHandle->bundle->getFile(fileName, offs, len); #ifndef USE_VORBIS - if (cmpFile) + if (len) error("Vorbis library compiled support needed!"); #endif - assert(cmpFile); + assert(len); oggMode = true; } if (!soundHandle->compressedStream) { -- cgit v1.2.3