From d4fce188448a273306b0c1c915e7bd91d6f83a6e Mon Sep 17 00:00:00 2001 From: John Snow Date: Sat, 10 Mar 2018 03:27:26 -0500 Subject: [PATCH] blockjobs: fix set-speed kick If speed is '0' it's not actually "less than" the previous speed. Kick the job in this case too. Signed-off-by: John Snow Reviewed-by: Eric Blake Reviewed-by: Kevin Wolf Signed-off-by: Kevin Wolf --- blockjob.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/blockjob.c b/blockjob.c index 801d29d849..afd92db01f 100644 --- a/blockjob.c +++ b/blockjob.c @@ -499,7 +499,7 @@ void block_job_set_speed(BlockJob *job, int64_t speed, Error **errp) } job->speed = speed; - if (speed <= old_speed) { + if (speed && speed <= old_speed) { return; }