[Spice-devel,spice-server,04/22] reds: use bool for RedsState::seamless_migration_enabled

Submitted by Frediano Ziglio on June 16, 2017, 9:13 a.m.

Details

Message ID 20170616091334.31475-5-fziglio@redhat.com
State New
Headers show
Series "reds: Use bool for boolean types" ( rev: 6 5 4 3 2 1 ) in Spice

Not browsing as part of any series.

Commit Message

Frediano Ziglio June 16, 2017, 9:13 a.m.
Signed-off-by: Frediano Ziglio <fziglio@redhat.com>
---
 server/reds-private.h | 2 +-
 server/reds.c         | 6 +++---
 2 files changed, 4 insertions(+), 4 deletions(-)

Patch hide | download patch | download mbox

diff --git a/server/reds-private.h b/server/reds-private.h
index 78571ac..227827d 100644
--- a/server/reds-private.h
+++ b/server/reds-private.h
@@ -107,7 +107,7 @@  struct RedsState {
     MonitorMode monitor_mode;
     SpiceTimer *mig_timer;
 
-    int vm_running;
+    bool vm_running;
     GList *char_devices; /* list of SpiceCharDeviceState */
     bool seamless_migration_enabled; /* command line arg */
 
diff --git a/server/reds.c b/server/reds.c
index 7363735..5b6bb1a 100644
--- a/server/reds.c
+++ b/server/reds.c
@@ -3396,7 +3396,7 @@  static int do_spice_init(RedsState *reds, SpiceCoreInterface *core_interface)
     reds->mig_target_clients = NULL;
     reds->char_devices = NULL;
     reds->mig_wait_disconnect_clients = NULL;
-    reds->vm_running = TRUE; /* for backward compatibility */
+    reds->vm_running = true; /* for backward compatibility */
 
     if (!(reds->mig_timer = reds->core.timer_add(&reds->core, migrate_timeout, reds))) {
         spice_error("migration timer create failed");
@@ -4199,7 +4199,7 @@  SPICE_GNUC_VISIBLE void spice_server_vm_start(SpiceServer *reds)
 {
     GList *it;
 
-    reds->vm_running = TRUE;
+    reds->vm_running = true;
     for (it = reds->char_devices; it != NULL; it = it->next) {
         red_char_device_start(it->data);
     }
@@ -4210,7 +4210,7 @@  SPICE_GNUC_VISIBLE void spice_server_vm_stop(SpiceServer *reds)
 {
     GList *it;
 
-    reds->vm_running = FALSE;
+    reds->vm_running = false;
     for (it = reds->char_devices; it != NULL; it = it->next) {
         red_char_device_stop(it->data);
     }