diff options
author | Niels de Vos <ndevos@redhat.com> | 2017-07-26 16:17:03 +0200 |
---|---|---|
committer | Jeff Darcy <jeff@pl.atyp.us> | 2017-07-29 20:55:18 +0000 |
commit | 1bc3cd9bd59e3826fd14fc239322f039d7a814da (patch) | |
tree | 498cc4b92852e9d9f9242ad9db40d0e75e68aa89 /xlators/features/changelog | |
parent | 5fe8555800cbc9818e7c976f63499795a378cd8d (diff) |
changelog: add mem-pool initialization
With recent changes to the mem-pool initialization,
mem_pools_init_early() and mem_pools_init_late() need to be called
before mem_get() is usable.
This change has been tested manually with the included test from
xlators/features/changelog/lib/examples/c/get-changes.c.
Change-Id: I139563c4ff78a566cef2ff7e3da2ee10306def92
BUG: 1475255
Reported-by: Kotresh HR <khiremat@redhat.com>
Signed-off-by: Niels de Vos <ndevos@redhat.com>
Reviewed-on: https://review.gluster.org/17900
Smoke: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Kotresh HR <khiremat@redhat.com>
CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
Reviewed-by: Jeff Darcy <jeff@pl.atyp.us>
Diffstat (limited to 'xlators/features/changelog')
-rw-r--r-- | xlators/features/changelog/lib/src/gf-changelog.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/xlators/features/changelog/lib/src/gf-changelog.c b/xlators/features/changelog/lib/src/gf-changelog.c index 0e5a2c844e0..e4ad045599a 100644 --- a/xlators/features/changelog/lib/src/gf-changelog.c +++ b/xlators/features/changelog/lib/src/gf-changelog.c @@ -173,6 +173,8 @@ gf_changelog_cleanup_this (xlator_t *this) this->private = NULL; this->ctx = NULL; + + mem_pools_fini (); } static int @@ -206,7 +208,13 @@ gf_changelog_init_context () static int gf_changelog_init_master () { - return gf_changelog_init_context (); + int ret = 0; + + mem_pools_init_early (); + ret = gf_changelog_init_context (); + mem_pools_init_late (); + + return ret; } /* TODO: cleanup clnt/svc on failure */ |