On Sat, Jul 15, 2017 at 14:42:39 +0800, xinhua.Cao wrote:
From: caoxinhua <caoxinhua(a)huawei.com>
when we start a vm, we call JOB_MASK(QEMU_JOB_NONE), then 1 << -1 will be execute.
we fix it as return 0
---
src/libxl/libxl_domain.h | 2 +-
src/qemu/qemu_domain.h | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
[....]
index 365b23c..6750215 100644
--- a/src/qemu/qemu_domain.h
+++ b/src/qemu/qemu_domain.h
@@ -51,7 +51,7 @@
# define QEMU_DOMAIN_MIG_BANDWIDTH_MAX (INT64_MAX / (1024 * 1024))
# endif
-# define JOB_MASK(job) (1 << (job - 1))
+# define JOB_MASK(job) (job == 0 ? 0 : 1 << (job - 1))
This makes QEMU_JOB_NONE and QEMU_JOB_QUERY to have the same result.
I think you need to fix some other place.
What is the problem you are seeing?