From 2f7237ac78bb70342bb1db16b4ee725d0c5dedfa Mon Sep 17 00:00:00 2001 From: Bastien Montagne Date: Tue, 16 Feb 2016 22:18:49 +0100 Subject: Fix broken ghash performance gtest. Regression from rB2dba2b3d71d9781bce45. Do not understand why MSVC needs this convoluted allocation (looks like broken compiler crap?), but at least let's do it correctly! --- tests/gtests/blenlib/BLI_ghash_performance_test.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/gtests/blenlib/BLI_ghash_performance_test.cc b/tests/gtests/blenlib/BLI_ghash_performance_test.cc index 972d1f6909c..817f0b3d10a 100644 --- a/tests/gtests/blenlib/BLI_ghash_performance_test.cc +++ b/tests/gtests/blenlib/BLI_ghash_performance_test.cc @@ -339,7 +339,7 @@ static void int4_ghash_tests(GHash *ghash, const char *id, const unsigned int nb { printf("\n========== STARTING %s ==========\n", id); - void *data_v = MEM_mallocN(sizeof(unsigned int (*)[4]) * (size_t)nbr, __func__); + void *data_v = MEM_mallocN(sizeof(unsigned int[4]) * (size_t)nbr, __func__); unsigned int (*data)[4] = (unsigned int (*)[4])data_v; unsigned int (*dt)[4]; unsigned int i, j; -- cgit v1.2.3