[thin_delta] Allow optional arg when using -m

This commit is contained in:
Joe Thornber
2015-07-28 11:26:58 +01:00
parent 93fb540bd4
commit 3a881e9513
3 changed files with 22 additions and 16 deletions

View File

@@ -188,10 +188,8 @@ namespace thin_provisioning {
read_superblock(open_bm(path, block_manager<>::READ_ONLY, false), 0);
uint64_t ms = sb.metadata_snap_;
if (!ms) {
cerr << "no metadata snapshot found!" << endl;
exit(1);
}
if (!ms)
throw runtime_error("no metadata snapshot found!\n");
return ms;
}