From: Xing Lin Date: Tue, 5 Nov 2013 05:25:42 +0000 (-0700) Subject: osd/ErasureCodePlugin: close library before return on error X-Git-Tag: v0.73~25^2 X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F819%2Fhead;p=ceph.git osd/ErasureCodePlugin: close library before return on error close and free resources for library before return Signed-off-by: Xing Lin --- diff --git a/src/osd/ErasureCodePlugin.cc b/src/osd/ErasureCodePlugin.cc index d8b9ae0fbbd8..38ea56a174c2 100644 --- a/src/osd/ErasureCodePlugin.cc +++ b/src/osd/ErasureCodePlugin.cc @@ -112,6 +112,7 @@ int ErasureCodePluginRegistry::load(const std::string &plugin_name, if (r != 0) { derr << "erasure_code_init(" << plugin_name << "): " << strerror(-r) << dendl; + dlclose(library); return r; } } else {