core: do not destroy in object pool's apply scope

Destroying an object within the scope of a lambda/functor executed
in the object pool's apply function leads potentially to memory corruption.
Within the scope the corresponding object is locked and unlocked when
leaving the scope. Therefore, it is illegal to free the object's memory meanwhile.
This commit eliminates several places in core that destroyed wrongly in
the object pool's scope.

Fix #1713
This commit is contained in:
Stefan Kalkowski
2015-09-23 08:37:12 +02:00
committed by Christian Helmuth
parent 6616bd4593
commit b585583ec7
13 changed files with 90 additions and 73 deletions

View File

@ -183,7 +183,7 @@ namespace Genode {
* by themselves and call this function to perform the actual
* killing.
*/
void _unsynchronized_kill_thread(Cpu_thread_component *thread);
void _unsynchronized_kill_thread(Thread_capability cap);
public: