Commit 2caf5a03 authored by Jimmy Yang's avatar Jimmy Yang

Fix Bug #54764 memory allocated in os_aio_array_create is not

freed at shutdown

rb://395, approved by Sunny Bains
parent 305e3330
......@@ -3233,6 +3233,9 @@ os_aio_array_create(
#endif
#if defined(LINUX_NATIVE_AIO)
array->aio_ctx = NULL;
array->aio_events = NULL;
/* If we are not using native aio interface then skip this
part of initialization. */
if (!srv_use_native_aio) {
......@@ -3313,6 +3316,13 @@ os_aio_array_free(
os_event_free(array->not_full);
os_event_free(array->is_empty);
#if defined(LINUX_NATIVE_AIO)
if (srv_use_native_aio) {
ut_free(array->aio_events);
ut_free(array->aio_ctx);
}
#endif /* LINUX_NATIVE_AIO */
ut_free(array->slots);
ut_free(array);
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment