rump_fs: handle non-existing root directory

This commit is contained in:
Sebastian Sumpf 2016-02-12 08:53:07 +01:00 committed by Josef Söntgen
parent 3680a79f38
commit 6b1923bbe6
1 changed files with 8 additions and 2 deletions

View File

@ -440,8 +440,14 @@ class File_system::Root : public Root_component<Session_component>
ram_quota, session_size); ram_quota, session_size);
throw Root::Quota_exceeded(); throw Root::Quota_exceeded();
} }
return new (md_alloc())
Session_component(tx_buf_size, _ep, root_dir, writeable, *md_alloc()); try {
return new (md_alloc())
Session_component(tx_buf_size, _ep, root_dir, writeable, *md_alloc());
} catch (Lookup_failed) {
PERR("File system root directory \"%s\" does not exist", root_dir);
throw Root::Unavailable();
}
} }
public: public: