aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/lib/X11/locking.c
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2013-03-07 23:46:05 -0800
committerUlrich Sibiller <uli42@gmx.de>2016-10-19 21:40:27 +0200
commite15023b2ad2a5ca8742cbb93fe10cb38ab079831 (patch)
treeac6b9de01f8f71b15392cc5216e53220da288e75 /nx-X11/lib/X11/locking.c
parent47d0ea1ba5bdd53d5df2cd06ffb637c889cf5e03 (diff)
downloadnx-libs-e15023b2ad2a5ca8742cbb93fe10cb38ab079831.tar.gz
nx-libs-e15023b2ad2a5ca8742cbb93fe10cb38ab079831.tar.bz2
nx-libs-e15023b2ad2a5ca8742cbb93fe10cb38ab079831.zip
Remove more unnecessary casts from Xmalloc/calloc calls
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/locking.c')
-rw-r--r--nx-X11/lib/X11/locking.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/nx-X11/lib/X11/locking.c b/nx-X11/lib/X11/locking.c
index b3dfb3b01..7c09c44d2 100644
--- a/nx-X11/lib/X11/locking.c
+++ b/nx-X11/lib/X11/locking.c
@@ -82,7 +82,7 @@ _Xthread_waiter(void)
struct _xthread_waiter *me;
if (!(me = TlsGetValue(_X_TlsIndex))) {
- me = (struct _xthread_waiter *)xmalloc(sizeof(struct _xthread_waiter));
+ me = xmalloc(sizeof(struct _xthread_waiter));
me->sem = CreateSemaphore(NULL, 0, 1, NULL);
me->next = NULL;
TlsSetValue(_X_TlsIndex, me);
@@ -249,7 +249,7 @@ static struct _XCVList *_XCreateCVL(
dpy->lock->free_cvls = cvl->next;
dpy->lock->num_free_cvls--;
} else {
- cvl = (struct _XCVList *)Xmalloc(sizeof(struct _XCVList));
+ cvl = Xmalloc(sizeof(struct _XCVList));
if (!cvl)
return NULL;
cvl->cv = xcondition_malloc();
@@ -512,10 +512,10 @@ void _XUserUnlockDisplay(
static int _XInitDisplayLock(
Display *dpy)
{
- dpy->lock_fns = (struct _XLockPtrs*)Xmalloc(sizeof(struct _XLockPtrs));
+ dpy->lock_fns = Xmalloc(sizeof(struct _XLockPtrs));
if (dpy->lock_fns == NULL)
return -1;
- dpy->lock = (struct _XLockInfo *)Xmalloc(sizeof(struct _XLockInfo));
+ dpy->lock = Xmalloc(sizeof(struct _XLockInfo));
if (dpy->lock == NULL) {
_XFreeDisplayLock(dpy);
return -1;