From 5a6b9120be8ced2c52a90c26af17a35501f37115 Mon Sep 17 00:00:00 2001 From: Dennis Potter Date: Wed, 4 Jul 2018 10:39:13 +0200 Subject: [PATCH] Fixed incompatible integer to pointer conversion returning 'int' from a function with result type 'struct memory_allocation *' --- lib/memory/heap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/memory/heap.c b/lib/memory/heap.c index 1a2c61552..7e054fd23 100644 --- a/lib/memory/heap.c +++ b/lib/memory/heap.c @@ -43,7 +43,7 @@ static struct memory_allocation * memory_heap_alloc(struct memory_type *m, size_ ret = posix_memalign(&ma->address, ma->alignment, ma->length); if (ret) { free(ma); - return ret; + return NULL; } return ma;