mirror of
https://github.com/genodelabs/genode.git
synced 2025-04-16 15:29:57 +00:00
Construct process member as late as possible
When creating a 'Child' object with an already active entrypoint, session requests may arrive as soon as the '_process' is created. We have to make sure that at least all parts of the 'Child' object needed for serving 'session' requests are constructed. This is particularly important for the '_policy' member.
This commit is contained in:
parent
2eca297232
commit
e4f28625e3
@ -287,16 +287,14 @@ namespace Genode {
|
||||
Rpc_entrypoint *_entrypoint;
|
||||
Parent_capability _parent_cap;
|
||||
|
||||
Process _process;
|
||||
/* child policy */
|
||||
Child_policy *_policy;
|
||||
|
||||
/* sessions opened by the child */
|
||||
Lock _lock; /* protect list manipulation */
|
||||
Object_pool<Session> _session_pool;
|
||||
List<Session> _session_list;
|
||||
|
||||
/* child policy */
|
||||
Child_policy *_policy;
|
||||
|
||||
/* server role */
|
||||
Server _server;
|
||||
|
||||
@ -305,6 +303,8 @@ namespace Genode {
|
||||
*/
|
||||
char _args[Parent::Session_args::MAX_SIZE];
|
||||
|
||||
Process _process;
|
||||
|
||||
/**
|
||||
* Attach session information to a child
|
||||
*
|
||||
@ -379,9 +379,9 @@ namespace Genode {
|
||||
_heap(&_ram_session_client, env()->rm_session()),
|
||||
_entrypoint(entrypoint),
|
||||
_parent_cap(_entrypoint->manage(this)),
|
||||
_process(elf_ds, ram, cpu, rm, _parent_cap, policy->name(), 0),
|
||||
_policy(policy),
|
||||
_server(ram)
|
||||
_server(ram),
|
||||
_process(elf_ds, ram, cpu, rm, _parent_cap, policy->name(), 0)
|
||||
{ }
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user