From 393ba0cf165028b2021cadfd9b2cbff02d942986 Mon Sep 17 00:00:00 2001 From: Campbell Barton Date: Sat, 29 Jul 2017 08:18:20 +1000 Subject: Cleanup: multistatement-macros warning --- source/blender/blenlib/BLI_array.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'source/blender/blenlib/BLI_array.h') diff --git a/source/blender/blenlib/BLI_array.h b/source/blender/blenlib/BLI_array.h index 74f24c808ff..3ffca818c0d 100644 --- a/source/blender/blenlib/BLI_array.h +++ b/source/blender/blenlib/BLI_array.h @@ -135,11 +135,12 @@ void _bli_array_grow_func(void **arr_p, const void *arr_static, #define BLI_array_append_ret(arr) \ (BLI_array_reserve(arr, 1), &arr[(_##arr##_count++)]) -#define BLI_array_free(arr) \ +#define BLI_array_free(arr) { \ if (arr && (char *)arr != _##arr##_static) { \ BLI_array_fake_user(arr); \ MEM_freeN(arr); \ - } (void)0 + } \ +} ((void)0) #define BLI_array_pop(arr) ( \ (arr && _##arr##_count) ? \ -- cgit v1.2.3