aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/lib/X11/XDefaultOMIF.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2013-08-10 23:51:08 -0700
committerUlrich Sibiller <uli42@gmx.de>2016-10-19 21:40:28 +0200
commitc161df4fee61819a28089682963cc2e721ca22c8 (patch)
tree00c3f8e2c0aba620b35cc7301acef494898a9542 /nx-X11/lib/X11/XDefaultOMIF.c
parent5d6cda4f6442c524db3c52b272f7ff5f7225bec6 (diff)
downloadnx-libs-c161df4fee61819a28089682963cc2e721ca22c8.tar.gz
nx-libs-c161df4fee61819a28089682963cc2e721ca22c8.tar.bz2
nx-libs-c161df4fee61819a28089682963cc2e721ca22c8.zip
Remove even more casts of return values from Xmalloc/Xrealloc
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com> Backported-to-NX-by: Ulrich Sibiller <uli42@gmx.de>
Diffstat (limited to 'nx-X11/lib/X11/XDefaultOMIF.c')
-rw-r--r--nx-X11/lib/X11/XDefaultOMIF.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/nx-X11/lib/X11/XDefaultOMIF.c b/nx-X11/lib/X11/XDefaultOMIF.c
index a8faa2af1..71dc810eb 100644
--- a/nx-X11/lib/X11/XDefaultOMIF.c
+++ b/nx-X11/lib/X11/XDefaultOMIF.c
@@ -76,7 +76,7 @@ Sun Microsystems, Inc. or its licensors is granted.
#define XOC_GENERIC(font_set) (&((XOCGeneric) font_set)->gen)
#define DefineLocalBuf char local_buf[BUFSIZ]
-#define AllocLocalBuf(length) (length > BUFSIZ ? (char *)Xmalloc(length) : local_buf)
+#define AllocLocalBuf(length) (length > BUFSIZ ? Xmalloc(length) : local_buf)
#define FreeLocalBuf(ptr) if (ptr != local_buf) Xfree(ptr)
typedef struct _FontDataRec {
@@ -332,15 +332,15 @@ init_core_part(
if (count == 0)
return False;
- font_struct_list = (XFontStruct **) Xmalloc(sizeof(XFontStruct *));
+ font_struct_list = Xmalloc(sizeof(XFontStruct *));
if (font_struct_list == NULL)
return False;
- font_name_list = (char **) Xmalloc(sizeof(char *));
+ font_name_list = Xmalloc(sizeof(char *));
if (font_name_list == NULL)
goto err;
- font_name_buf = (char *) Xmalloc(length);
+ font_name_buf = Xmalloc(length);
if (font_name_buf == NULL)
goto err;
@@ -578,11 +578,11 @@ set_missing_list(
if (count == 0)
return True;
- charset_list = (char **) Xmalloc(sizeof(char *));
+ charset_list = Xmalloc(sizeof(char *));
if (charset_list == NULL)
return False;
- charset_buf = (char *) Xmalloc(length);
+ charset_buf = Xmalloc(length);
if (charset_buf == NULL) {
Xfree(charset_list);
return False;
@@ -1172,11 +1172,11 @@ init_om(
length += strlen(data->font_data->name) + 1;
/* required charset list */
- required_list = (char **) Xmalloc(sizeof(char *));
+ required_list = Xmalloc(sizeof(char *));
if (required_list == NULL)
return False;
- bufptr = (char *) Xmalloc(length);
+ bufptr = Xmalloc(length);
if (bufptr == NULL) {
Xfree(required_list);
return False;
@@ -1192,7 +1192,7 @@ init_om(
bufptr += strlen(bufptr) + 1;
/* orientation list */
- orientation = (XOrientation *) Xmalloc(sizeof(XOrientation));
+ orientation = Xmalloc(sizeof(XOrientation));
if (orientation == NULL)
return False;