From 10a1d7489db2522670fb8d549e4750b3024bbc1b Mon Sep 17 00:00:00 2001 From: Glenn Maynard Date: Thu, 4 Dec 2003 20:33:33 +0000 Subject: [PATCH] get_length_fmt_adpcm fix --- stepmania/src/RageSoundReader_WAV.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/stepmania/src/RageSoundReader_WAV.cpp b/stepmania/src/RageSoundReader_WAV.cpp index 506178813a..02741d62a6 100644 --- a/stepmania/src/RageSoundReader_WAV.cpp +++ b/stepmania/src/RageSoundReader_WAV.cpp @@ -195,10 +195,7 @@ int RageSoundReader_WAV::seek_sample_fmt_normal( Uint32 ms ) int RageSoundReader_WAV::get_length_fmt_adpcm() const { - this->rw.Rewind(); - - int offset = this->rw.Tell(); - offset -= fmt.data_starting_offset; + int offset = this->rw.GetFileSize() - fmt.data_starting_offset; /* pcm bytes per block */ const int bpb = (adpcm.wSamplesPerBlock * fmt.adpcm_sample_frame_size);