rand: ensure that rand_between() can reach max value
authorJens Axboe <axboe@kernel.dk>
Tue, 12 Jun 2018 17:37:16 +0000 (11:37 -0600)
committerJens Axboe <axboe@kernel.dk>
Tue, 12 Jun 2018 17:37:16 +0000 (11:37 -0600)
commitc6fc6d2ab2c2fb905ea859f051ad66a54c607916
tree61834ab5be76debeb001dbb526d8e2cc9e551029
parent5630eccf1e7336095804ee635504dc333c4d519f
rand: ensure that rand_between() can reach max value

We need to add 1, otherwise the maximum generated value will
be end -1. The API is both inclusive.

Signed-off-by: Jens Axboe <axboe@kernel.dk>
lib/rand.h