|
1 | 1 | /*****************************************************************************
|
2 | 2 |
|
3 | 3 | Copyright (C) 2013, 2014, Fusion-io. All Rights Reserved.
|
4 |
| -Copyright (C) 2013, 2015, MariaDB Corporation. All Rights Reserved. |
| 4 | +Copyright (C) 2013, 2017, MariaDB Corporation. All Rights Reserved. |
5 | 5 |
|
6 | 6 | This program is free software; you can redistribute it and/or modify it under
|
7 | 7 | the terms of the GNU General Public License as published by the Free Software
|
@@ -486,14 +486,13 @@ buf_mtflu_handler_init(
|
486 | 486 | mtflush_heap2 = mem_heap_create(0);
|
487 | 487 | ut_a(mtflush_heap2 != NULL);
|
488 | 488 |
|
489 |
| - mtflush_ctx = (thread_sync_t *)mem_heap_alloc(mtflush_heap, |
| 489 | + mtflush_ctx = (thread_sync_t *)mem_heap_zalloc(mtflush_heap, |
490 | 490 | sizeof(thread_sync_t));
|
491 |
| - memset(mtflush_ctx, 0, sizeof(thread_sync_t)); |
| 491 | + |
492 | 492 | ut_a(mtflush_ctx != NULL);
|
493 |
| - mtflush_ctx->thread_data = (thread_data_t*)mem_heap_alloc( |
| 493 | + mtflush_ctx->thread_data = (thread_data_t*)mem_heap_zalloc( |
494 | 494 | mtflush_heap, sizeof(thread_data_t) * n_threads);
|
495 | 495 | ut_a(mtflush_ctx->thread_data);
|
496 |
| - memset(mtflush_ctx->thread_data, 0, sizeof(thread_data_t) * n_threads); |
497 | 496 |
|
498 | 497 | mtflush_ctx->n_threads = n_threads;
|
499 | 498 | mtflush_ctx->wq = ib_wqueue_create();
|
|
0 commit comments