Alberto Garcia b5806108d2 throttle: Assert that bkt->max is valid in throttle_compute_wait()
If bkt->max == 0 and bkt->burst_length > 1 then we could have a
division by 0 in throttle_do_compute_wait(). That configuration is
however not permitted and is already detected by throttle_is_valid(),
but let's assert it in throttle_compute_wait() to make it explicit.

Found by Coverity (CID: 1381016).

Signed-off-by: Alberto Garcia <berto@igalia.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Kevin Wolf <kwolf@redhat.com>
2017-09-26 14:46:23 +02:00
..
2017-04-11 20:07:15 +08:00
2017-09-22 14:11:25 +02:00
2017-09-22 14:11:23 +02:00
2017-09-07 19:02:30 +01:00
2016-02-04 17:01:04 +00:00
2016-02-04 17:01:04 +00:00
2016-06-16 18:39:03 +02:00
2016-02-04 17:01:04 +00:00
2017-08-11 14:12:44 +02:00
2016-02-04 17:01:04 +00:00
2016-02-04 17:01:04 +00:00
2017-06-16 07:55:00 +08:00
2016-09-23 11:42:52 +08:00