}
API int appinfo_internal_filter_get_list(sqlite3 *db,
- pkgmgrinfo_appinfo_filter_h filter, uid_t uid,
+ pkgmgrinfo_appinfo_filter_h filter, uid_t db_uid, uid_t uid,
const char *locale, GHashTable *appinfo_list)
{
int ret;
return PMINFO_R_EINVAL;
}
- ret = _appinfo_get_applications(db, uid, uid, locale, filter,
+ ret = _appinfo_get_applications(db, db_uid, uid, locale, filter,
PMINFO_APPINFO_GET_ALL, appinfo_list);
return ret;
}
int ret = PMINFO_R_OK;
for (auto conn : conn_list) {
ret = appinfo_internal_filter_get_list(conn.first, filter_, conn.second,
- GetLocale().c_str(), list);
+ uid_, GetLocale().c_str(), list);
if (ret == PMINFO_R_ERROR) {
_LOGD("Failed to appinfo_internal_filter_get_list (%d)", ret);
break;
return PMINFO_R_OK;
}
-// TODO: Need to add target db uid to identify which database to be searched
-extern "C" EXPORT_API int _appinfo_get_applications(uid_t db_uid, uid_t uid,
+extern "C" EXPORT_API int _appinfo_get_applications(uid_t uid,
pkgmgrinfo_filter_x* filter, int flag, GHashTable* packages) {
std::shared_ptr<pcp::AbstractParcelable> parcelable(
new pcp::FilterParcelable(uid,
int _pkginfo_get_depends_on(uid_t uid,
const char *pkgid, GList **dependencies);
-int _appinfo_get_applications(uid_t db_uid, uid_t uid,
+int _appinfo_get_applications(uid_t uid,
pkgmgrinfo_filter_x *filter, int flag, GHashTable *packages);
char *_appinfo_get_localed_label(const char *appid, const char *locale,
if (list == NULL)
return PMINFO_R_ERROR;
- ret = _appinfo_get_applications(uid, uid, filter,
+ ret = _appinfo_get_applications(uid, filter,
PMINFO_APPINFO_GET_ALL, list);
if (ret != PMINFO_R_OK) {
g_hash_table_destroy(list);
if (list == NULL)
return PMINFO_R_ERROR;
- ret = _appinfo_get_applications(uid, uid, filter,
+ ret = _appinfo_get_applications(uid, filter,
flag | PMINFO_APPINFO_GET_BASICINFO, list);
if (ret == PMINFO_R_ERROR) {
g_hash_table_destroy(list);
}
}
- ret = _appinfo_get_applications(uid, uid, filter, 0, list);
+ ret = _appinfo_get_applications(uid, filter, 0, list);
query_count = g_hash_table_size(list);
g_hash_table_destroy(list);
if (ret == PMINFO_R_ERROR)
#endif
int pkginfo_internal_filter_get_list(sqlite3 *db, pkgmgrinfo_pkginfo_filter_h filter, uid_t uid, const char *locale, GHashTable *list);
-int appinfo_internal_filter_get_list(sqlite3 *db, pkgmgrinfo_appinfo_filter_h filter, uid_t uid, const char *locale, GHashTable *list);
+int appinfo_internal_filter_get_list(sqlite3 *db, pkgmgrinfo_appinfo_filter_h filter, uid_t db_uid, uid_t uid, const char *locale, GHashTable *list);
int certinfo_internal_get(sqlite3 *db, const char *pkgid, uid_t uid, pkgmgrinfo_certinfo_h certinfo);
int certinfo_internal_set(sqlite3 *db, const char *pkgid, pkgmgrinfo_instcertinfo_h handle, uid_t uid);
int certinfo_internal_delete(sqlite3 *db, const char *pkgid);