From cd6b27f2b58aff46c9431bf7621e19bdb1b0b4c2 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Tue, 21 May 2013 07:37:59 +0000 Subject: remove return value from MEM_freeN, it wasn't used anywhere and was cast to a different function signature. (which evidently works but error prone). --- intern/guardedalloc/MEM_guardedalloc.h | 2 +- intern/guardedalloc/intern/mallocn.c | 5 ++--- 2 files changed, 3 insertions(+), 4 deletions(-) (limited to 'intern') diff --git a/intern/guardedalloc/MEM_guardedalloc.h b/intern/guardedalloc/MEM_guardedalloc.h index a3988bef92a..beffaece865 100644 --- a/intern/guardedalloc/MEM_guardedalloc.h +++ b/intern/guardedalloc/MEM_guardedalloc.h @@ -82,7 +82,7 @@ extern "C" { /** * Release memory previously allocatred by this module. */ - short MEM_freeN(void *vmemh); + void MEM_freeN(void *vmemh); #if 0 /* UNUSED */ /** diff --git a/intern/guardedalloc/intern/mallocn.c b/intern/guardedalloc/intern/mallocn.c index 7eb603b8207..2f6b91b9711 100644 --- a/intern/guardedalloc/intern/mallocn.c +++ b/intern/guardedalloc/intern/mallocn.c @@ -743,7 +743,7 @@ void MEM_printmemlist_pydict(void) MEM_printmemlist_internal(1); } -short MEM_freeN(void *vmemh) +void MEM_freeN(void *vmemh) { short error = 0; MemTail *memt; @@ -1065,10 +1065,9 @@ size_t MEM_allocN_len(const void *vmemh) return malloc_usable_size((void *)vmemh); } -short MEM_freeN(void *vmemh) +void MEM_freeN(void *vmemh) { free(vmemh); - return 1; } void *MEM_dupallocN(const void *vmemh) -- cgit v1.2.3