This commit is contained in:
Glenn Maynard
2006-12-10 07:20:13 +00:00
parent ecbbe89f1a
commit 7d0754c2a6
+3 -2
View File
@@ -161,7 +161,7 @@ bool must_be_eof( RageSoundReader *snd )
{ {
char buf[16]; char buf[16];
int got = snd->Read( buf, 1 ); int got = snd->Read( buf, 1 );
return got == 0; return got == RageSoundReader::END_OF_FILE;
} }
const int FILTER_NONE = 0; const int FILTER_NONE = 0;
@@ -390,8 +390,9 @@ bool RunTests( RageSoundReader *snd, const TestFile &tf )
{ {
char buf[4096]; char buf[4096];
int got = snd->Read( buf, sizeof(buf) / (snd->GetNumChannels() * sizeof(int16_t)) ); int got = snd->Read( buf, sizeof(buf) / (snd->GetNumChannels() * sizeof(int16_t)) );
if( got == 0 ) if( got == RageSoundReader::END_OF_FILE )
break; break;
ASSERT( got >= 0 );
} }
/* Now, make sure reading after an EOF returns another EOF. */ /* Now, make sure reading after an EOF returns another EOF. */