changeset 1475:1c5688582a4e

fixed modplug, wasn't working properly with new threading model
author Giacomo Lozito <james@develia.org>
date Sat, 11 Aug 2007 22:15:50 +0200
parents 10791910b866
children c6947f95fd2a
files src/modplug/modplugbmp.cxx
diffstat 1 files changed, 2 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/src/modplug/modplugbmp.cxx	Sat Aug 11 18:10:34 2007 +0300
+++ b/src/modplug/modplugbmp.cxx	Sat Aug 11 22:15:50 2007 +0200
@@ -25,6 +25,7 @@
 ModplugXMMS::ModplugXMMS()
 {
 	mSoundFile = new CSoundFile;
+	mOutPlug = NULL;
 }
 ModplugXMMS::~ModplugXMMS()
 {
@@ -490,7 +491,7 @@
 
 float32 ModplugXMMS::GetTime(void)
 {
-	if(mStopped)
+	if ((mStopped) || (!mOutPlug))
 		return -1;
 	return (float32)mOutPlug->output_time() / 1000;
 }