Tue, 19 Sep 2017 14:35:08 +0200
explicit cast from (void*) for (ucx_memchunk*) to silence a warning
ucx/mempool.c | file | annotate | diff | comparison | revisions |
--- a/ucx/mempool.c Tue Sep 19 14:16:26 2017 +0200 +++ b/ucx/mempool.c Tue Sep 19 14:35:08 2017 +0200 @@ -115,7 +115,8 @@ } } - ucx_memchunk *mem = (ucx_memchunk*)malloc(sizeof(ucx_destructor) + n); + void *p = malloc(sizeof(ucx_destructor) + n); + ucx_memchunk *mem = (ucx_memchunk*)p; if (!mem) { return NULL; }