From: Junghyun Yeon Date: Thu, 21 Sep 2017 11:24:03 +0000 (+0900) Subject: Fix memory leak X-Git-Tag: accepted/tizen/4.0/unified/20170927.181735~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=refs%2Fchanges%2F66%2F151666%2F1;p=platform%2Fcore%2Fappfw%2Fapp-installers.git Fix memory leak - Newly allocated manifest variable is not assigned at installer context at that time and it will be leaked if any of function calls in FillManifestX has failed. Change-Id: I33c4525d37a2f9a3a19074288246ce6e06af749a Signed-off-by: Junghyun Yeon --- diff --git a/src/common/step/configuration/step_parse_manifest.cc b/src/common/step/configuration/step_parse_manifest.cc index 0816899..767957c 100644 --- a/src/common/step/configuration/step_parse_manifest.cc +++ b/src/common/step/configuration/step_parse_manifest.cc @@ -1179,6 +1179,7 @@ Step::Status StepParseManifest::process() { if (!FillManifestX(const_cast(manifest))) { LOG(ERROR) << "[Parse] Storing manifest_x failed. " << parser_->GetErrorMessage(); + pkgmgr_parser_free_manifest_xml(manifest); return Step::Status::PARSE_ERROR; }