|
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Xen-devel] [PATCH 3/9] xl: turn some int local variable into bool
more specifically, the ones used as argument presence
flags in `xl list'.
Signed-off-by: Dario Faggioli <dario.faggioli@xxxxxxxxxx>
Cc: Ian Campbell <ian.campbell@xxxxxxxxxx>
Cc: Ian Jackson <Ian.Jackson@xxxxxxxxxxxxx>
Cc: Stefano Stabellini <stefano.stabellini@xxxxxxxxxxxxx>
Cc: Wei Liu <wei.liu2@xxxxxxxxxx>
---
tools/libxl/xl_cmdimpl.c | 19 ++++++++++---------
1 file changed, 10 insertions(+), 9 deletions(-)
diff --git a/tools/libxl/xl_cmdimpl.c b/tools/libxl/xl_cmdimpl.c
index 5c40e84..69469ff 100644
--- a/tools/libxl/xl_cmdimpl.c
+++ b/tools/libxl/xl_cmdimpl.c
@@ -3520,7 +3520,7 @@ static void print_bitmap(uint8_t *map, int maplen, FILE
*stream)
}
}
-static void list_domains(int verbose, int context, int claim, int numa,
+static void list_domains(bool verbose, bool context, bool claim, bool numa,
const libxl_dominfo *info, int nb_domain)
{
int i;
@@ -4504,10 +4504,11 @@ int main_reboot(int argc, char **argv)
int main_list(int argc, char **argv)
{
- int opt, verbose = 0;
- int context = 0;
- int details = 0;
- int numa = 0;
+ int opt;
+ bool verbose = false;
+ bool context = false;
+ bool details = false;
+ bool numa = false;
static struct option opts[] = {
{"long", 0, 0, 'l'},
{"verbose", 0, 0, 'v'},
@@ -4523,16 +4524,16 @@ int main_list(int argc, char **argv)
SWITCH_FOREACH_OPT(opt, "lvhZn", opts, "list", 0) {
case 'l':
- details = 1;
+ details = true;
break;
case 'v':
- verbose = 1;
+ verbose = true;
break;
case 'Z':
- context = 1;
+ context = true;
break;
case 'n':
- numa = 1;
+ numa = true;
break;
}
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel
|
![]() |
Lists.xenproject.org is hosted with RackSpace, monitoring our |