aboutsummaryrefslogtreecommitdiffhomepage
diff options
context:
space:
mode:
authorGravatar Mark D. Roth <roth@google.com>2017-04-20 07:10:22 -0700
committerGravatar Mark D. Roth <roth@google.com>2017-04-20 07:10:22 -0700
commit493be1f1b98d3c238b9b87fc478c3f4ae25444af (patch)
treea6193791cfe8bdacb418f815d9c2c5aa0b3e3234
parentf186d9d35b93bed6cb47e2902eb3caf4d43be55e (diff)
Fix windows build.
-rw-r--r--test/core/slice/slice_hash_table_test.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/core/slice/slice_hash_table_test.c b/test/core/slice/slice_hash_table_test.c
index 055d7f448f..67041b2d5c 100644
--- a/test/core/slice/slice_hash_table_test.c
+++ b/test/core/slice/slice_hash_table_test.c
@@ -116,10 +116,12 @@ static void test_slice_hash_table() {
};
const size_t num_entries = GPR_ARRAY_SIZE(test_entries);
// Construct table.
- grpc_slice_hash_table_entry entries[num_entries];
+ grpc_slice_hash_table_entry* entries =
+ gpr_zalloc(sizeof(*entries) * num_entries);
populate_entries(test_entries, num_entries, entries);
grpc_slice_hash_table* table =
grpc_slice_hash_table_create(num_entries, entries, destroy_string);
+ gpr_free(entries);
// Check contents of table.
check_values(test_entries, num_entries, table);
check_non_existent_value("XX", table);