Add nullptr error handling in part_blk, fix #1586

This commit is contained in:
Taru Karttunen 2015-06-16 14:03:01 +03:00 committed by Christian Helmuth
parent 80893dfcfc
commit 5fec78fcd6

View File

@ -72,6 +72,11 @@ int main()
if (valid_mbr) if (valid_mbr)
partition_table = &Mbr_partition_table::table(); partition_table = &Mbr_partition_table::table();
if (!partition_table) {
PERR("Aborting: no partition table found.");
return 1;
}
enum { STACK_SIZE = 1024 * sizeof(Genode::size_t) }; enum { STACK_SIZE = 1024 * sizeof(Genode::size_t) };
static Cap_connection cap; static Cap_connection cap;
static Rpc_entrypoint ep(&cap, STACK_SIZE, "part_ep"); static Rpc_entrypoint ep(&cap, STACK_SIZE, "part_ep");