[Spice-commits] Branch '0.8' - client/x11

Alon Levy alon at kemper.freedesktop.org
Thu Mar 22 02:18:55 PDT 2012


 client/x11/images/alt_image.c |    4 ++--
 client/x11/images/red_icon.c  |    4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

New commits:
commit da1b0ee3d267a611f950f3122aa513fce689506a
Author: Alon Levy <alevy at redhat.com>
Date:   Wed Mar 14 16:51:51 2012 +0200

    client: fix two narrowing conversion c++-11 warnings
    
    Warnings are from initializing members of type int from uint32_t. Fix is
    to change alt_image and red_icon height and width fields to ints.
    
    Example warning fixed:
     res.cpp:58:1: error: narrowing conversion of ‘_red_icon.<anonymous
     struct>::width’ from ‘const uint32_t {aka const unsigned int}’ to ‘int’
     inside { } is ill-formed in C++11 [-Werror=narrowing]
    
    Signed-off-by: Alon Levy <alevy at redhat.com>

diff --git a/client/x11/images/alt_image.c b/client/x11/images/alt_image.c
index 7968339..e11cf1f 100644
--- a/client/x11/images/alt_image.c
+++ b/client/x11/images/alt_image.c
@@ -1,6 +1,6 @@
 static const struct {
-	uint32_t width;
-	uint32_t height;
+	int width;
+	int height;
 	uint8_t pixel_data[17496];
 } _alt_image = { 81, 54, {
 		0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,
diff --git a/client/x11/images/red_icon.c b/client/x11/images/red_icon.c
index ce1a7d4..143d4e2 100644
--- a/client/x11/images/red_icon.c
+++ b/client/x11/images/red_icon.c
@@ -1,6 +1,6 @@
 static const struct {
-    uint32_t width;
-    uint32_t height;
+    int width;
+    int height;
     uint8_t pixmap[4096];
     uint8_t mask[128];
 } _red_icon = { 32, 32, {


More information about the Spice-commits mailing list