mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-07 19:34:56 +00:00
base: catch 'Ipc_error' in 'Expanding_parent_client::exit()'
If a component is being destroyed just before it calls `exit()` at its parent, the `exit()` call causes an `Ipc_error` exception, which leads to an `abort()` loop with repeated error messages, because `abort()` calls `exit()` too. Catching the exception in `Expanding_parent_client::exit()` avoids this problem. Fixes #3228
This commit is contained in:
parent
98e2f91036
commit
67fd77d10a
@ -93,6 +93,20 @@ class Genode::Expanding_parent_client : public Parent_client
|
||||
** Parent interface **
|
||||
**********************/
|
||||
|
||||
void exit(int exit_value) override
|
||||
{
|
||||
try {
|
||||
Parent_client::exit(exit_value);
|
||||
} catch (Genode::Ipc_error) {
|
||||
/*
|
||||
* This can happen if the child is being destroyed before
|
||||
* calling 'exit()'. Catching the exception avoids an
|
||||
* 'abort()' loop with repeated error messages, because
|
||||
* 'abort()' calls 'exit()' too.
|
||||
*/
|
||||
}
|
||||
}
|
||||
|
||||
Session_capability session(Client::Id id,
|
||||
Service_name const &name,
|
||||
Session_args const &args,
|
||||
|
Loading…
x
Reference in New Issue
Block a user