From: Inkyun Kil Date: Mon, 3 Apr 2017 04:30:31 +0000 (+0900) Subject: Fix memory leak X-Git-Tag: submit/tizen/20170404.075729^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=64d15dadffb77a56baebac5024ead13ccd21309d;p=platform%2Fcore%2Fappfw%2Fevent-system.git Fix memory leak Change-Id: If280dd2155b75cabc42f7a2d4a8544b8707dfb65 Signed-off-by: Inkyun Kil --- diff --git a/src/esd_main.c b/src/esd_main.c index 93e096a..cb00e9e 100644 --- a/src/esd_main.c +++ b/src/esd_main.c @@ -1010,18 +1010,21 @@ static int __esd_get_user_items(void) PMINFO_APPINFO_PROP_APP_COMPONENT, "svcapp"); if (ret < 0) { _E("failed to add appinfo filter string"); + pkgmgrinfo_appinfo_filter_destroy(handle); return ES_R_ERROR; } ret = pkgmgrinfo_appinfo_filter_add_string(handle, PMINFO_APPINFO_PROP_APP_OPERATION, APPSVC_OPERATION_LAUNCH_ON_EVENT); if (ret < 0) { _E("failed to add appinfo filter string"); + pkgmgrinfo_appinfo_filter_destroy(handle); return ES_R_ERROR; } ret = pkgmgrinfo_appinfo_usr_filter_foreach_appinfo(handle, __esd_add_appinfo_handler, &cur_uid, cur_uid); if (ret < 0) { _E("appinfo filter foreach error"); + pkgmgrinfo_appinfo_filter_destroy(handle); return ES_R_ERROR; } pkgmgrinfo_appinfo_filter_destroy(handle);