Memory leak on the second setWorldGeometry() call

sjcomp

28-02-2006 19:43:00

When I call setWorldGeometry() for the second time I get a memory leak created inside OgrePagingLandScapeSceneManager.cpp PagingLandScapeSceneManager::setWorldGeometry(DataStreamPtr& stream, const String& typeName)

mOptions = new PagingLandScapeOptions(this);

Curently mOptions is deleted only in the destuctor.

I added the following and it fixed the problem


if(!mOptions)
mOptions = new PagingLandScapeOptions(this);


I am using CVS HEAD for Ogre and PLSM2

tuan kuranes

28-02-2006 20:23:56

thanks for the report !
Missed that one on the new multiple scene manager code.