Patch to make the configure flag for mpd-mad and mpd-libid3tag more logic (from ticho)

git-svn-id: https://svn.musicpd.org/mpd/trunk@3477 09075e82-0dd4-0310-85a5-a0d7c8717e4f
This commit is contained in:
Qball Cow
2005-09-08 21:08:02 +00:00
parent bc666a9fc6
commit edcfbef90d
12 changed files with 84 additions and 15 deletions

View File

@@ -212,10 +212,17 @@ MpdTag * modTagDup(char * file) {
MODULE * moduleHandle;
char * title;
if(mod_initMikMod() < 0) return NULL;
if(mod_initMikMod() < 0) {
DEBUG("modTagDup: Failed to initialize MikMod\n");
return NULL;
}
if(!(moduleHandle = Player_Load(file, 128, 0))) goto fail;
if(!(moduleHandle = Player_Load(file, 128, 0))) {
DEBUG("modTagDup: Failed to open file: %s\n",file);
MikMod_Exit();
return NULL;
}
Player_Free(moduleHandle);
ret = newMpdTag();
@@ -224,7 +231,6 @@ MpdTag * modTagDup(char * file) {
title = strdup(Player_LoadTitle(file));
if(title) addItemToMpdTag(ret, TAG_ITEM_TITLE, title);
fail:
MikMod_Exit();
return ret;