+ _save_column_str(stmt, idx++, &info->appid);
+ if (g_hash_table_contains(applications,
+ (gconstpointer)info->appid)) {
+ free(info->appid);
+ free(info);
+ info = NULL;
+ continue;
+ }
+ _save_column_str(stmt, idx++, &info->component);
+ _save_column_str(stmt, idx++, &info->exec);
+ _save_column_str(stmt, idx++, &info->nodisplay);
+ _save_column_str(stmt, idx++, &info->type);
+ _save_column_str(stmt, idx++, &info->onboot);
+ _save_column_str(stmt, idx++, &info->multiple);
+ _save_column_str(stmt, idx++, &info->autorestart);
+ _save_column_str(stmt, idx++, &info->taskmanage);
+ _save_column_str(stmt, idx++, &info->hwacceleration);
+ _save_column_str(stmt, idx++, &info->screenreader);
+ _save_column_str(stmt, idx++, &info->mainapp);
+ _save_column_str(stmt, idx++, &info->recentimage);
+ _save_column_str(stmt, idx++, &info->launchcondition);
+ _save_column_str(stmt, idx++, &info->indicatordisplay);
+ _save_column_str(stmt, idx++, &info->portraitimg);
+ _save_column_str(stmt, idx++, &info->landscapeimg);
+ _save_column_str(stmt, idx++, &info->guestmode_visibility);
+ _save_column_str(stmt, idx++, &info->permission_type);
+ _save_column_str(stmt, idx++, &info->preload);
+ _save_column_str(stmt, idx++, &info->submode);
+ _save_column_str(stmt, idx++, &info->submode_mainid);
+ _save_column_str(stmt, idx++, &info->launch_mode);
+ _save_column_str(stmt, idx++, &info->ui_gadget);
+ _save_column_str(stmt, idx++, &info->support_disable);
+ _save_column_str(stmt, idx++, &info->process_pool);
+ _save_column_str(stmt, idx++, &info->installed_storage);
+ _save_column_str(stmt, idx++, &bg_category_str);
+ _save_column_str(stmt, idx++, &info->package_type);
+ _save_column_str(stmt, idx++, &info->root_path);
+ _save_column_str(stmt, idx++, &info->api_version);
+ _save_column_str(stmt, idx++, &info->effective_appid);
+ _save_column_str(stmt, idx++, &info->is_disabled);
+ _save_column_str(stmt, idx++, &info->splash_screen_display);
+ _save_column_str(stmt, idx++, &info->tep_name);
+ _save_column_str(stmt, idx++, &info->zip_mount_file);
+ _save_column_str(stmt, idx++, &info->component_type);
+ _save_column_str(stmt, idx++, &info->package);
+ _save_column_str(stmt, idx++, &info->external_path);
+ _save_column_str(stmt, idx++, &info->package_system);
+ _save_column_str(stmt, idx++, &info->removable);
+ _save_column_str(stmt, idx++, &info->package_installed_time);
+ _save_column_str(stmt, idx++, &info->support_mode);
+ _save_column_str(stmt, idx++, &info->support_ambient);
+ _save_column_str(stmt, idx++, &info->setup_appid);
+
+ info->for_all_users =
+ strdup((db_uid != GLOBAL_USER) ? "false" : "true");
+
+ if (db_uid == GLOBAL_USER) {
+ ret = __get_appinfo_for_uid(db, info, uid);
+ if (ret != PMINFO_R_OK) {
+ LOGI("Failed to get appinfo for given uid[%d]", (int)uid);
+ pkgmgrinfo_basic_free_application(info);
+ info = NULL;
+ continue;
+ }
+ }