summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndrei Elkin <andrei.elkin@pp.inet.fi>2018-11-01 16:06:03 +0200
committerAndrei Elkin <andrei.elkin@pp.inet.fi>2018-11-01 16:06:03 +0200
commitdafbd50e8a09340022e5207d2223372666fdabc8 (patch)
tree34b4aed4684e603f3c1d9f2705d92902b80201ec
parent8d834cd0f370b306f63c2364552d187fc388e59e (diff)
downloadmariadb-git-dafbd50e8a09340022e5207d2223372666fdabc8.tar.gz
MDEV-17133 follow-up patch to fix mf_iocache-t unittest
which did not always correctly simulated io-cache::end_of_file. The error was caused by implicit cast to unsigned of an intemediate term in a formula.
-rw-r--r--unittest/sql/mf_iocache-t.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/unittest/sql/mf_iocache-t.cc b/unittest/sql/mf_iocache-t.cc
index 95451d52f86..1eef8365074 100644
--- a/unittest/sql/mf_iocache-t.cc
+++ b/unittest/sql/mf_iocache-t.cc
@@ -326,7 +326,7 @@ void mdev17133()
MY_MIN(sizeof(buf_o),
info.end_of_file + eof_block_size +
// plus 25% of block for randomization to the average
- (eof_block_size/4 - rand() % (eof_block_size/2)));
+ eof_block_size/4 - rand() % (eof_block_size/2));
// read a chunk by blocks of variable size read_iter times
// the last block completes the current chunk