mirror of
https://github.com/genodelabs/genode.git
synced 2025-05-29 13:44:26 +00:00
Translate buffer-exceeded exception in Session_requester
Session_requester inherits from Dynamic_rom_session::Content_producer which specifies the Buffer_capacity_exceeded exception which is thrown on insufficient buffer space.
This commit is contained in:
parent
c18dffa9fa
commit
78f1fd29f7
@ -35,9 +35,13 @@ class Genode::Session_requester
|
|||||||
|
|
||||||
void produce_content(char *dst, Genode::size_t dst_len) override
|
void produce_content(char *dst, Genode::size_t dst_len) override
|
||||||
{
|
{
|
||||||
Xml_generator xml(dst, dst_len, "session_requests", [&] () {
|
try {
|
||||||
_id_space.for_each<Session_state const>([&] (Session_state const &s) {
|
Xml_generator xml(dst, dst_len, "session_requests", [&] () {
|
||||||
s.generate_session_request(xml); }); });
|
_id_space.for_each<Session_state const>([&] (Session_state const &s) {
|
||||||
|
s.generate_session_request(xml); }); });
|
||||||
|
} catch (Xml_generator::Buffer_exceeded &) {
|
||||||
|
throw Buffer_capacity_exceeded();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
} _content_producer { _id_space };
|
} _content_producer { _id_space };
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user