From: Ilho Kim Date: Fri, 15 Nov 2019 05:19:59 +0000 (+0900) Subject: Fix "using value after free" issue X-Git-Tag: accepted/tizen/5.5/unified/20191118.084807~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=629eec289f363e47cae456d76a6797670c610db0;p=platform%2Fcore%2Fappfw%2Fpkgmgr-info.git Fix "using value after free" issue If bg_category_str is not set by _save_column_str, __get_background_category use freed value Change-Id: I5c1a4dda131df42ebf15627fd0fe72fc8038c972 Signed-off-by: Ilho Kim --- diff --git a/src/pkgmgrinfo_appinfo.c b/src/pkgmgrinfo_appinfo.c index 12a9b7d..ad93c86 100644 --- a/src/pkgmgrinfo_appinfo.c +++ b/src/pkgmgrinfo_appinfo.c @@ -621,6 +621,7 @@ static int _appinfo_get_applications(uid_t db_uid, uid_t uid, info->background_category = __get_background_category( bg_category_str); free(bg_category_str); + bg_category_str = NULL; } info->for_all_users =