[spice v1 2/2] display-channel: monitors config debug: add head number

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

 



From: Victor Toso <me@xxxxxxxxxxxxxx>

The difference is subtle but compared to what client receives, this
could help identify values set to the wrong head, e.g:

First we received:
 | display-channel.c:180:monitors_config_debug: monitors config count:2 max:4
 | display-channel.c:184:monitors_config_debug: +0+0 1015x805
 | display-channel.c:184:monitors_config_debug: +1015+0 1024x740

And then:
 | display-channel.c:180:monitors_config_debug: monitors config count:3 max:4
 | display-channel.c:184:monitors_config_debug: +0+0 1015x805
 | display-channel.c:184:monitors_config_debug: +0+0 0x0
 | display-channel.c:184:monitors_config_debug: +1015+0 1024x740

In the first debug it would be helpful to have "head 0" and "head 1",
to point out the temporary error in monitor's config message.

Signed-off-by: Victor Toso <victortoso@xxxxxxxxxx>
---
 server/display-channel.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/server/display-channel.c b/server/display-channel.c
index 7e2584ec..1a9af106 100644
--- a/server/display-channel.c
+++ b/server/display-channel.c
@@ -179,10 +179,11 @@ static void monitors_config_debug(MonitorsConfig *mc)
     int i;
 
     spice_debug("monitors config count:%d max:%d", mc->count, mc->max_allowed);
-    for (i = 0; i < mc->count; i++)
-        spice_debug("+%d+%d %dx%d",
+    for (i = 0; i < mc->count; i++) {
+        spice_debug("head #%d +%d+%d %dx%d", i,
                     mc->heads[i].x, mc->heads[i].y,
                     mc->heads[i].width, mc->heads[i].height);
+    }
 }
 
 static MonitorsConfig* monitors_config_new(QXLHead *heads, ssize_t nheads, ssize_t max)
-- 
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]