mirror of
https://github.com/genodelabs/genode.git
synced 2025-01-31 08:25:38 +00:00
core: fix regression in sig context ownership test
This patch fixes a problem similar to issue #2065 but for the freeing of signal contexts.
This commit is contained in:
parent
8d1cf08b1a
commit
a845bdafeb
@ -75,18 +75,22 @@ class Genode::Signal_broker
|
||||
|
||||
void free_context(Signal_context_capability context_cap)
|
||||
{
|
||||
Signal_context_component *context;
|
||||
Signal_context_component *context = nullptr;
|
||||
|
||||
_context_ep.apply(context_cap, [&] (Signal_context_component *c) {
|
||||
context = c;
|
||||
if (!context) {
|
||||
|
||||
if (!c) {
|
||||
warning("specified signal-context capability has wrong type");
|
||||
return;
|
||||
}
|
||||
|
||||
context = c;
|
||||
|
||||
_context_ep.dissolve(context);
|
||||
});
|
||||
destroy(&_contexts_slab, context);
|
||||
|
||||
if (context)
|
||||
destroy(&_contexts_slab, context);
|
||||
}
|
||||
|
||||
void submit(Signal_context_capability cap, unsigned cnt)
|
||||
|
Loading…
x
Reference in New Issue
Block a user