blk-bench: don't write if not requested

Because a check for the TEST_WRITE configuration was missing as condition for a
packet submit, the test caused unwanted write access to the device.

Ref #1824
This commit is contained in:
Martin Stein 2015-12-16 14:49:27 +01:00 committed by Christian Helmuth
parent 96649c716d
commit 852b799cd4
1 changed files with 3 additions and 0 deletions

View File

@ -46,6 +46,9 @@ class Test::Throughput
{
static size_t count = REQUEST_SIZE / _blk_size;
if (_read_done && (_write_done || !TEST_WRITE))
return;
try {
while (_session.tx()->ready_to_submit()) {
Block::Packet_descriptor p(