]> xenbits.xensource.com Git - people/iwj/xen.git/commit
libxl: Change claim_mode from bool to int.
authorKonrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Mon, 13 May 2013 19:29:12 +0000 (15:29 -0400)
committerIan Campbell <ian.campbell@citrix.com>
Tue, 14 May 2013 09:02:00 +0000 (10:02 +0100)
commit93b241e9d2c23b75f400a9ccda40838b9d13e27d
tree2dbefc5b94d337822d69830eb7da3c8c95a31a47
parentbec8f17e48439ee5b8370f4e431ccd9a9514bee7
libxl: Change claim_mode from bool to int.

During the review it was noticed that it would be better if internally
the claim_mode was held as an 'int' instead of a 'bool'. The reason
is that during the startup of xl, one has call the libxl_defbool_setdefault.
otherwise any usage of claim_mode would result in assert break.

The assert is due to the fact that using defbool without any set
values (either true of false) will cause it hit an assertion.

If we use an 'int' we don't have to worry about it and by default
the value of zero will suffice for checks whether the claim is
enabled or disabled.

Signed-off-by: Konrad Rzeszutek Wilk <konrad.wilk@oracle.com>
Acked-by: Ian Campbell <Ian.Campbell@citrix.com>
tools/libxl/xl.c
tools/libxl/xl.h
tools/libxl/xl_cmdimpl.c