init: forward RAM/cap quota session errors

This patch supplements init's service-forwarding mechanism to propagate
the insufficient RAM/cap quota conditions from the server to the client.
Without it, the client's session request stays pending infinitely.
This commit is contained in:
Norman Feske 2017-11-10 15:10:01 +01:00 committed by Christian Helmuth
parent 44977e3519
commit 72f2ea349d

View File

@ -145,6 +145,12 @@ void Init::Server::session_ready(Session_state &session)
if (session.phase == Session_state::SERVICE_DENIED)
_close_session(session, Parent::SERVICE_DENIED);
if (session.phase == Session_state::INSUFFICIENT_RAM_QUOTA)
_close_session(session, Parent::INSUFFICIENT_RAM_QUOTA);
if (session.phase == Session_state::INSUFFICIENT_CAP_QUOTA)
_close_session(session, Parent::INSUFFICIENT_CAP_QUOTA);
}