[PATCH spice-server] red-worker: Use bool for driver_cap_monitors_config

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Easier to understand.

Signed-off-by: Frediano Ziglio <fziglio@xxxxxxxxxx>
---
 server/red-worker.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/server/red-worker.c b/server/red-worker.c
index bc63fc34f..a30148a55 100644
--- a/server/red-worker.c
+++ b/server/red-worker.c
@@ -83,7 +83,7 @@ struct RedWorker {
     RedStatCounter full_loop_counter;
     RedStatCounter total_loop_counter;
 
-    int driver_cap_monitors_config;
+    bool driver_cap_monitors_config;
 
     RedRecord *record;
     GMainLoop *loop;
@@ -646,7 +646,7 @@ static void handle_dev_monitors_config_async(void *opaque, void *payload)
         /* TODO: raise guest bug (requires added QXL interface) */
         goto async_complete;
     }
-    worker->driver_cap_monitors_config = 1;
+    worker->driver_cap_monitors_config = true;
     count = dev_monitors_config->count;
     max_allowed = dev_monitors_config->max_allowed;
     if (count == 0) {
@@ -752,7 +752,7 @@ static void handle_dev_driver_unload(void *opaque, void *payload)
 {
     RedWorker *worker = opaque;
 
-    worker->driver_cap_monitors_config = 0;
+    worker->driver_cap_monitors_config = false;
 }
 
 static
@@ -1076,7 +1076,7 @@ RedWorker* red_worker_new(QXLInstance *qxl)
         dispatcher_register_universal_handler(dispatcher, worker_dispatcher_record);
     }
 
-    worker->driver_cap_monitors_config = 0;
+    worker->driver_cap_monitors_config = false;
     char worker_str[SPICE_STAT_NODE_NAME_MAX];
     snprintf(worker_str, sizeof(worker_str), "display[%d]", worker->qxl->id & 0xff);
     stat_init_node(&worker->stat, reds, NULL, worker_str, TRUE);
-- 
2.20.1

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux Virtualization]     [Linux Virtualization]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]