typedef int (*INSERT_STORAGE)(sqlite3 *, const char *, int, const char *, uid_t);
typedef int (*UPDATE_STORAGE)(sqlite3 *, const char *, const char *, uid_t);
typedef int (*SET_STORAGE_VALIDITY)(sqlite3 *, const char *, int, uid_t uid);
-typedef int (*SET_ALL_STORAGE_VALIDITY)(int, uid_t);
+typedef int (*SET_ALL_STORAGE_VALIDITY)(sqlite3 *, int, uid_t);
typedef int (*UPDATE_ITEM_META)(const char *, const char *, int, uid_t);
typedef int (*UPDATE_ITEM_BEGIN)(int);
int ms_insert_storage(sqlite3 *handle, const char *storage_id, const char *storage_path, uid_t uid);
int ms_update_storage(sqlite3 *handle, const char *storage_id, const char *storage_path, uid_t uid);
int ms_set_storage_validity(sqlite3 *handle, const char *storage_id, int validity, uid_t uid);
-int ms_set_all_storage_validity(int validity, uid_t uid);
+int ms_set_all_storage_validity(sqlite3 *handle, int validity, uid_t uid);
int ms_update_meta_batch(const char *path, const char *storage_id, uid_t uid);
int ms_delete_invalid_folder_by_path(sqlite3 *handle, const char *storage_id, const char *folder_path, uid_t uid);
int ms_check_folder_exist(sqlite3 *handle, const char *storage_id, const char *folder_path);
return ret;
}
-int ms_set_all_storage_validity(int validity, uid_t uid)
+int ms_set_all_storage_validity(sqlite3 *handle, int validity, uid_t uid)
{
int lib_index;
int ret = MS_MEDIA_ERR_NONE;
for (lib_index = 0; lib_index < lib_num; lib_index++) {
- ret = ((SET_ALL_STORAGE_VALIDITY)func_array[lib_index][eSET_ALL_STORAGE_VALIDITY])(validity, uid); /*dlopen*/
+ ret = ((SET_ALL_STORAGE_VALIDITY)func_array[lib_index][eSET_ALL_STORAGE_VALIDITY])(handle, validity, uid); /*dlopen*/
MS_DBG_RETVM_IF(ret != MS_MEDIA_ERR_NONE, ret, "Error : %s", g_array_index(so_array, char*, lib_index));
}
MS_DBG_ERR("ms_set_storage_scan_status fail");
/*update just valid type*/
- if (ms_set_all_storage_validity(0, uid) != MS_MEDIA_ERR_NONE)
+ if (ms_set_all_storage_validity(db_handle, 0, uid) != MS_MEDIA_ERR_NONE)
MS_DBG_ERR("ms_set_all_storage_validity fail");
#ifdef _USE_TVPD_MODE