Change-Id: I35851682a958f42dfbf1492b4a424381f6b4ed87
Signed-off-by: Junghoon Park <jh9216.park@samsung.com>
ret = _appinfo_get_applications(GLOBAL_USER, uid, locale, filter,
PMINFO_APPINFO_GET_ALL, list);
+ if (ret != PMINFO_R_OK) {
+ g_hash_table_destroy(list);
+ free(locale);
+ return ret;
+ }
+
if (!g_hash_table_size(list)) {
_LOGD("appinfo for [%s] is not existed for user [%d]",
appid, uid);
ret = _pkginfo_get_packages(GLOBAL_USER, locale, filter,
PMINFO_PKGINFO_GET_ALL, list);
+ if (ret != PMINFO_R_OK) {
+ g_hash_table_destroy(list);
+ free(locale);
+ return ret;
+ }
+
if (!g_hash_table_size(list)) {
_LOGD("pkginfo for [%s] is not existed for user [%d]",
pkgid, uid);