fix crash

This commit is contained in:
Thai Pangsakulyanont
2011-03-10 00:36:23 +07:00
parent c1f4967f1c
commit 742304fb73
+6 -1
View File
@@ -784,7 +784,12 @@ static void ReadGlobalTags( const NameToData_t &mapNameToData, Song &out, Measur
// this is keysound file name. Looks like "#WAV1A"
RString sData = it->second;
RString sWavID = sName.Right(2);
// FIXME: garbled song names seem to crash the app.
// this might not be the best place to put this code.
if( !utf8_is_valid(sData) )
continue;
/* Due to bugs in some programs, many BMS files have a "WAV" extension
* on files in the BMS for files that actually have some other extension.
* Do a search. Don't do a wildcard search; if sData is "song.wav",