fix a crash with failure to open second file for dual-file stereo

git-svn-id: https://vgmstream.svn.sourceforge.net/svnroot/vgmstream@258 51a99a44-fe44-0410-b1ba-c3e57ba2b86b
This commit is contained in:
halleyscometsw 2008-06-26 02:08:26 +00:00
parent c433b3046f
commit fb54dabcd4

View File

@ -957,7 +957,8 @@ void try_dual_file_stereo(VGMSTREAM * opened_stream, STREAMFILE *streamFile) {
#endif #endif
dual_stream = streamFile->open(streamFile,filename2,STREAMFILE_DEFAULT_BUFFER_SIZE); dual_stream = streamFile->open(streamFile,filename2,STREAMFILE_DEFAULT_BUFFER_SIZE);
// no need to check NULL here since init_vgmstream_internal does it at its beginning if (!dual_stream) goto fail;
new_stream = init_vgmstream_internal(dual_stream, new_stream = init_vgmstream_internal(dual_stream,
0 /* don't do dual file on this, to prevent recursion */ 0 /* don't do dual file on this, to prevent recursion */
); );