Browse Source

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.
pull/923/head
Andrei Elkin 7 years ago
parent
commit
dafbd50e8a
  1. 2
      unittest/sql/mf_iocache-t.cc

2
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

Loading…
Cancel
Save