mirror of
https://github.com/vgmstream/vgmstream.git
synced 2025-01-18 15:54:05 +01:00
work with either all ucase or all lcase .wav name
git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@294 51a99a44-fe44-0410-b1ba-c3e57ba2b86b
This commit is contained in:
parent
d210bc5bfc
commit
6f4410dd2c
@ -26,11 +26,16 @@ VGMSTREAM * init_vgmstream_pos(STREAMFILE *streamFile) {
|
||||
/* check for .WAV file */
|
||||
strcpy(filenameWAV,filename);
|
||||
strcpy(filenameWAV+strlen(filenameWAV)-3,"wav");
|
||||
for (i=strlen(filenameWAV);i>=0&&filenameWAV[i]!=DIRSEP;i--)
|
||||
filenameWAV[i]=toupper(filenameWAV[i]);
|
||||
|
||||
streamFileWAV = streamFile->open(streamFile,filenameWAV,STREAMFILE_DEFAULT_BUFFER_SIZE);
|
||||
if (!streamFileWAV) goto fail;
|
||||
if (!streamFileWAV) {
|
||||
/* try again, ucase */
|
||||
for (i=strlen(filenameWAV);i>=0&&filenameWAV[i]!=DIRSEP;i--)
|
||||
filenameWAV[i]=toupper(filenameWAV[i]);
|
||||
|
||||
streamFileWAV = streamFile->open(streamFile,filenameWAV,STREAMFILE_DEFAULT_BUFFER_SIZE);
|
||||
if (!streamFileWAV) goto fail;
|
||||
}
|
||||
|
||||
/* let the real initer do the parsing */
|
||||
vgmstream = init_vgmstream_riff(streamFileWAV);
|
||||
|
Loading…
x
Reference in New Issue
Block a user