ram_block: use Number_of_bytes to parse block size

Using this helper rather than parsing as size_t directly allows use to
use size suffixes, e.g. K, M, G.

Fixes #3540.
This commit is contained in:
Josef Söntgen 2019-08-09 15:36:16 +02:00 committed by Christian Helmuth
parent ba9b612c4f
commit f5c5479faa
1 changed files with 2 additions and 1 deletions

View File

@ -174,7 +174,8 @@ struct Main
size = config.attribute_value("size", Number_of_bytes());
}
block_size = config.attribute_value("block_size", block_size);
block_size = config.attribute_value("block_size",
Number_of_bytes(block_size));
}
Block::Driver *create() override