[Xcb-commit] xcb-util
Vincent Torri
doursse at kemper.freedesktop.org
Thu Apr 20 01:00:44 PDT 2006
xcb-util/convenient/xcb_aux.c | 2 +-
xcb-util/icccm/icccm.c | 10 +++++-----
xcb-util/image/test_xcb_image.c | 10 +++++-----
3 files changed, 11 insertions(+), 11 deletions(-)
New commits:
diff-tree adaaf459fa4be95a51ec95a4b8baa0267da28cf4 (from 26c009705b0c87b89fec043dd1663fc3d9ed96fe)
Author: TORRI Vincent <torri at doursse.(none)>
Date: Thu Apr 20 09:59:43 2006 +0200
fix some warnings
diff --git a/xcb-util/convenient/xcb_aux.c b/xcb-util/convenient/xcb_aux.c
index 4456869..3241e49 100644
--- a/xcb-util/convenient/xcb_aux.c
+++ b/xcb-util/convenient/xcb_aux.c
@@ -32,7 +32,7 @@ XCBSCREEN *
XCBAuxGetScreen (XCBConnection *c,
int screen)
{
- XCBSCREENIter i = XCBConnSetupSuccessRepRootsIter(XCBGetSetup(c));
+ XCBSCREENIter i = XCBConnSetupSuccessRepRootsIter((XCBConnSetupSuccessRep *)XCBGetSetup(c));
for (; i.rem; --screen, XCBSCREENNext(&i))
if (screen == 0)
return i.data;
diff --git a/xcb-util/icccm/icccm.c b/xcb-util/icccm/icccm.c
index 90e4870..18716f2 100644
--- a/xcb-util/icccm/icccm.c
+++ b/xcb-util/icccm/icccm.c
@@ -442,13 +442,13 @@ GetWMSizeHints (XCBConnection *c,
(rep->format == 32)) &&
(rep->value_len >= 15)) /* OldNumPropSizeElements = 15 (pre-ICCCM) */
{
- long length;
- unsigned char *prop;
+ char *prop;
+ long length;
length = XCBGetPropertyValueLength (rep);
/* FIXME: in GetProp.c of xcl, one move the memory.
* Should we do that too ? */
- prop = (unsigned char *)malloc(sizeof(unsigned char)*length);
+ prop = (char *)malloc(sizeof(char)*length);
memcpy(prop, XCBGetPropertyValue (rep), length);
prop[length] = '\0';
hints = (SizeHints *)strdup (prop);
@@ -704,8 +704,8 @@ GetWMHints (XCBConnection *c,
XCBGetPropertyCookie cookie;
XCBGetPropertyRep *rep;
WMHints *hints;
+ char *prop;
long length;
- unsigned char *prop;
cookie = XCBGetProperty (c, 0, window,
WM_HINTS, WM_HINTS,
@@ -729,7 +729,7 @@ GetWMHints (XCBConnection *c,
}
length = XCBGetPropertyValueLength (rep);
- prop = (unsigned char *) XCBGetPropertyValue (rep);
+ prop = (char *) XCBGetPropertyValue (rep);
prop[length] = '\0';
hints = (WMHints *)strdup (prop);
if (rep->value_len < NumWMHintsElements)
diff --git a/xcb-util/image/test_xcb_image.c b/xcb-util/image/test_xcb_image.c
index dbe9576..36a2c7d 100644
--- a/xcb-util/image/test_xcb_image.c
+++ b/xcb-util/image/test_xcb_image.c
@@ -45,17 +45,17 @@ reflect_window (XCBConnection *c,
printf (" * bitmap order....: %d\n", image->bitmap_format_bit_order);
printf (" * bitmap pad......: %d\n", image->bitmap_format_scanline_pad);
printf (" * depth...........: %d\n", image->depth);
- printf (" * bytes/line......: %ld\n", image->bytes_per_line);
+ printf (" * bytes/line......: %d\n", image->bytes_per_line);
printf (" * bits/pixel......: %d\n", image->bits_per_pixel);
- printf ("bpl %ld %d\n", image->bytes_per_line, image->height);
+ printf ("bpl %d %d\n", image->bytes_per_line, image->height);
for (j = 0 ; j < image->height ; j++)
{
for (i = 0 ; i < image->width ; i++)
{
pixel1 = XCBImageGetPixel (image, i, j);
- printf ("%6ld ", pixel1);
+ printf ("%6d ", pixel1);
}
printf ("\n");
}
@@ -83,7 +83,7 @@ reflect_window (XCBConnection *c,
for (i = 0 ; i < image->width ; i++)
{
pixel1 = XCBImageGetPixel (image, i, j);
- printf ("%6ld ", pixel1);
+ printf ("%6d ", pixel1);
}
printf ("\n");
}
@@ -99,7 +99,7 @@ reflect_window (XCBConnection *c,
for (i = 0 ; i < image->width ; i++)
{
pixel1 = XCBImageGetPixel (image, i, j);
- printf ("%6ld ", pixel1);
+ printf ("%6d ", pixel1);
}
printf ("\n");
}
More information about the xcb-commit
mailing list