From 7307f3b48564191dfcf2ccd71e730c41c6486289 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Tue, 17 Feb 2015 15:50:12 +0500 Subject: Fix T43706: Creating a directory in the file browser (by typing it in the file path) crashes Blender Issue was caused by 2e9105c, free() does nothing if pointer is NULL, but guarded allocator expects you to not free NULL. --- source/blender/blenlib/intern/storage.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/source/blender/blenlib/intern/storage.c b/source/blender/blenlib/intern/storage.c index 90c4ac3bcdc..c6b65171478 100644 --- a/source/blender/blenlib/intern/storage.c +++ b/source/blender/blenlib/intern/storage.c @@ -459,7 +459,9 @@ void BLI_filelist_free(struct direntry *filelist, unsigned int nrentries, void ( free_poin(entry->poin); } - MEM_freeN(filelist); + if (filelist != NULL) { + MEM_freeN(filelist); + } } -- cgit v1.2.3