summaryrefslogtreecommitdiff
path: root/ui/vnc.c
diff options
context:
space:
mode:
authorGonglei <arei.gonglei@huawei.com>2015-01-30 10:14:36 +0800
committerGerd Hoffmann <kraxel@redhat.com>2015-02-16 08:47:59 +0100
commita2c72de09619ed4d2f4498a65027114f9c035f7f (patch)
tree38db0282dc1331b2c73c52c2c8d628b97c40caf7 /ui/vnc.c
parente2a11d9d5a7d8b8450cd644e73b829dcf4686528 (diff)
downloadqemu-a2c72de09619ed4d2f4498a65027114f9c035f7f.tar.gz
qemu-a2c72de09619ed4d2f4498a65027114f9c035f7f.tar.bz2
qemu-a2c72de09619ed4d2f4498a65027114f9c035f7f.zip
vnc: using bool type instead of int for QEMU_OPT_BOOL
Signed-off-by: Gonglei <arei.gonglei@huawei.com> Signed-off-by: Gerd Hoffmann <kraxel@redhat.com>
Diffstat (limited to 'ui/vnc.c')
-rw-r--r--ui/vnc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/ui/vnc.c b/ui/vnc.c
index 6a82d7f6b7..e7c35aa6b6 100644
--- a/ui/vnc.c
+++ b/ui/vnc.c
@@ -3318,8 +3318,8 @@ void vnc_display_open(const char *id, Error **errp)
QemuOpts *opts = qemu_opts_find(&qemu_vnc_opts, id);
const char *share, *device_id;
QemuConsole *con;
- int password = 0;
- int reverse = 0;
+ bool password = false;
+ bool reverse = false;
const char *vnc;
const char *has_to;
char *display, *to = NULL;
@@ -3329,11 +3329,11 @@ void vnc_display_open(const char *id, Error **errp)
const char *websocket;
#endif
#ifdef CONFIG_VNC_TLS
- int tls = 0, x509 = 0;
+ bool tls = false, x509 = false;
const char *path;
#endif
#ifdef CONFIG_VNC_SASL
- int sasl = 0;
+ bool sasl = false;
int saslErr;
#endif
#if defined(CONFIG_VNC_TLS) || defined(CONFIG_VNC_SASL)
@@ -3385,7 +3385,7 @@ void vnc_display_open(const char *id, Error **errp)
tls = qemu_opt_get_bool(opts, "tls", false);
path = qemu_opt_get(opts, "x509");
if (path) {
- x509 = 1;
+ x509 = true;
vs->tls.x509verify = qemu_opt_get_bool(opts, "x509verify", false);
if (vnc_tls_set_x509_creds_dir(vs, path) < 0) {
error_setg(errp, "Failed to find x509 certificates/keys in %s",