Merge pull request #1664 from erwincoumans/master
PyBullet: fix some memory leaks
This commit is contained in:
@@ -277,8 +277,8 @@ void b3PosixThreadSupport::stopThreads()
|
||||
destroySem(spuStatus.startSemaphore);
|
||||
printf("semaphore destroyed\n");
|
||||
checkPThreadFunction(pthread_join(spuStatus.thread,0));
|
||||
|
||||
}
|
||||
delete spuStatus.m_lsMemory;
|
||||
}
|
||||
printf("destroy main semaphore\n");
|
||||
destroySem(m_mainSemaphore);
|
||||
printf("main semaphore destroyed\n");
|
||||
|
||||
@@ -756,6 +756,12 @@ public:
|
||||
delete m_debugDraw;
|
||||
m_debugDraw = 0;
|
||||
}
|
||||
|
||||
for (int i=0;i<m_userDebugParams.size();i++)
|
||||
{
|
||||
delete m_userDebugParams[i];
|
||||
}
|
||||
m_userDebugParams.clear();
|
||||
}
|
||||
|
||||
void setCriticalSection(b3CriticalSection* cs)
|
||||
|
||||
@@ -3551,6 +3551,7 @@ static PyObject* pybullet_getJointStates(PyObject* self, PyObject* args, PyObjec
|
||||
return NULL;
|
||||
}
|
||||
}
|
||||
Py_DECREF(jointIndicesSeq);
|
||||
return resultListJointState;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user