mirror of
https://github.com/genodelabs/genode.git
synced 2025-06-19 23:53:55 +00:00
base: introduce Ram_allocator::try_alloc
This patch replaces the 'Ram_allocator::alloc' RPC function by a 'try_alloc' function, which reflects errors as 'Attempt' return value instead of an exception. Issue #4322 Issue #3612
This commit is contained in:
committed by
Christian Helmuth
parent
959bcae557
commit
231ac187fe
@ -79,7 +79,7 @@ class Stack_area_region_map : public Genode::Region_map
|
||||
|
||||
struct Stack_area_ram_allocator : Genode::Ram_allocator
|
||||
{
|
||||
Genode::Ram_dataspace_capability alloc(Genode::size_t, Genode::Cache) override {
|
||||
Alloc_result try_alloc(Genode::size_t, Genode::Cache) override {
|
||||
return Genode::Ram_dataspace_capability(); }
|
||||
|
||||
void free(Genode::Ram_dataspace_capability) override { }
|
||||
|
Reference in New Issue
Block a user