diff options
author | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-02-17 13:50:12 +0300 |
---|---|---|
committer | Sergey Sharybin <sergey.vfx@gmail.com> | 2015-02-17 13:55:18 +0300 |
commit | 7307f3b48564191dfcf2ccd71e730c41c6486289 (patch) | |
tree | e722b376a09619abd58e2d842026a3938d110d9a /source/blender/blenlib | |
parent | 2c1b0536c9e89eb401c422bed78edd3c35fb8b01 (diff) |
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.
Diffstat (limited to 'source/blender/blenlib')
-rw-r--r-- | source/blender/blenlib/intern/storage.c | 4 |
1 files changed, 3 insertions, 1 deletions
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); + } } |