[client] remove all casts around malloc

The cast is unnecessary in C and should be removed to avoid clutter.
This commit is contained in:
Quantum
2021-08-15 18:55:19 -04:00
committed by Geoffrey McRae
parent fd4a4114e6
commit 81c38e825c
12 changed files with 18 additions and 18 deletions

View File

@@ -216,7 +216,7 @@ void app_clipboardRequest(const LG_ClipboardReplyFn replyFn, void * opaque)
if (!g_params.clipboardToLocal)
return;
struct CBRequest * cbr = (struct CBRequest *)malloc(sizeof(*cbr));
struct CBRequest * cbr = malloc(sizeof(*cbr));
cbr->type = g_state.cbType;
cbr->replyFn = replyFn;
@@ -661,7 +661,7 @@ KeybindHandle app_registerKeybind(int sc, KeybindFn callback, void * opaque, con
return NULL;
}
KeybindHandle handle = (KeybindHandle)malloc(sizeof(*handle));
KeybindHandle handle = malloc(sizeof(*handle));
handle->sc = sc;
handle->callback = callback;
handle->opaque = opaque;