[Xcb-commit] image keysyms
Bart Massey
bart at kemper.freedesktop.org
Mon Oct 6 14:03:11 PDT 2008
image/xcb_image.c | 2 +-
keysyms/keysyms.c | 2 +-
2 files changed, 2 insertions(+), 2 deletions(-)
New commits:
commit 1c985f3a37e12b8b4bf45122bb33962ddf5e6ef4
Author: Ulrich Eckhardt <doomster at knuut.de>
Date: Mon Oct 6 14:02:24 2008 -0700
Do not cast the return value of malloc() in modern C.
Signed-off-by: Bart Massey <bart at cs.pdx.edu>
diff --git a/image/xcb_image.c b/image/xcb_image.c
index 2388948..701dda4 100644
--- a/image/xcb_image.c
+++ b/image/xcb_image.c
@@ -227,7 +227,7 @@ xcb_image_create (uint16_t width,
}
if (!format_valid(depth, bpp, unit, format, xpad))
return 0;
- image = (xcb_image_t *)malloc(sizeof(*image));
+ image = malloc(sizeof(*image));
if (image == 0)
return 0;
image->width = width;
diff --git a/keysyms/keysyms.c b/keysyms/keysyms.c
index 83c1d3d..4f432d1 100644
--- a/keysyms/keysyms.c
+++ b/keysyms/keysyms.c
@@ -49,7 +49,7 @@ xcb_key_symbols_alloc (xcb_connection_t *c)
if (!c)
return NULL;
- syms = (xcb_key_symbols_t *)malloc (sizeof (xcb_key_symbols_t));
+ syms = malloc (sizeof (xcb_key_symbols_t));
syms->c = c;
syms->tag = TAG_COOKIE;
More information about the xcb-commit
mailing list