Browse Source

Fix issue #169 by courtesy of lukaszbruun.

Calling Source::stop() in Source::~Source() could result in a infinite
recursion when Pool::removeSource released the source object.
vrld 14 years ago
parent
commit
0af7e9e0d8
1 changed files with 2 additions and 1 deletions
  1. 2 1
      src/modules/audio/openal/Source.cpp

+ 2 - 1
src/modules/audio/openal/Source.cpp

@@ -82,7 +82,8 @@ namespace openal
 
 	void Source::stop()
 	{
-		pool->stop(this);
+		if (!isStopped())
+			pool->stop(this);
 	}
 
 	void Source::pause()