core: throw Trace::Out_of_metadata in subjects()

While importing trace sources as trace subjects into a TRACE session,
the session quota might become depleted. The TRACE session already keeps
track of the session quota via an allocator guard but the 'subjects' RPC
function missed to handle the out-of-memory condition. This patch
reflects the error condition as an 'Out_of_metadata' exception to the
TRACE client. It also contains an extension of the trace test to
exercise the corner case.
This commit is contained in:
Norman Feske
2015-06-17 13:25:51 +02:00
committed by Christian Helmuth
parent 705257cf22
commit 5d678dba9e
4 changed files with 49 additions and 3 deletions

View File

@ -61,6 +61,8 @@ struct Genode::Trace::Session_client : Genode::Rpc_client<Genode::Trace::Session
/**
* Retrieve subject directory
*
* \throw Out_of_metadata
*/
size_t subjects(Subject_id *dst, size_t dst_len)
{