rewind the sound if preload fails

This commit is contained in:
Glenn Maynard
2003-03-31 22:20:11 +00:00
parent 971b2cba15
commit 26cc236bca
+4
View File
@@ -186,6 +186,10 @@ bool RageSound::Load(CString sSoundFilePath, int precache)
delete NewSample;
return true;
}
/* Preload failed. It read some data, so we need to rewind the
* reader. */
NewSample->SetPosition_Fast(0);
delete Preload;
}
stream.Sample = NewSample;