Name: media-server
Summary: A server for media content management
-Version: 0.3.66
+Version: 0.3.67
Release: 0
Group: Multimedia/Service
License: Apache-2.0
typedef int (*CHECK_DB)(void*, uid_t, char **);
typedef int (*GET_UUID)(void *, char **, char **);
typedef int (*CHECK_STORAGE)(void *, const char *, char **, int *, uid_t, char **);
-typedef int (*INSERT_STORAGE)(void *, const char *, int, const char *, const char *, uid_t, char **);
+typedef int (*INSERT_STORAGE)(void *, const char *, int, const char *, uid_t, char **);
typedef int (*UPDATE_STORAGE)(void *, const char *, const char *, uid_t, char **);
typedef int (*SET_STORAGE_VALIDITY)(void *, const char *, int, uid_t uid, char **);
typedef int (*SET_ALL_STORAGE_VALIDITY)(void *, int, uid_t, char **);
int ms_check_db_upgrade(void **handle, uid_t uid);
int ms_genarate_uuid(void **handle, char **uuid);
int ms_check_storage(void **handle, const char *storage_id, char **storage_path, int *validity, uid_t uid);
-int ms_insert_storage(void **handle, const char *storage_id, const char *storage_name, const char *storage_path, uid_t uid);
+int ms_insert_storage(void **handle, const char *storage_id, const char *storage_path, uid_t uid);
int ms_update_storage(void **handle, const char *storage_id, const char *storage_path, uid_t uid);
int ms_set_storage_validity(void **handle, const char *storage_id, int validity, uid_t uid);
int ms_set_all_storage_validity(void **handle, int validity, uid_t uid);
return res;
}
-int ms_insert_storage(void **handle, const char *storage_id, const char *storage_name, const char *storage_path, uid_t uid)
+int ms_insert_storage(void **handle, const char *storage_id, const char *storage_path, uid_t uid)
{
int lib_index = 0;
int res = MS_MEDIA_ERR_NONE;
MS_DBG_RETVM_IF(ret != MS_MEDIA_ERR_NONE, ret, "Fail to get storage type");
for (lib_index = 0; lib_index < lib_num; lib_index++) {
- ret = ((INSERT_STORAGE)func_array[lib_index][eINSERT_STORAGE])(handle[lib_index], storage_id, storage_type, storage_name, storage_path, uid, &err_msg);
+ ret = ((INSERT_STORAGE)func_array[lib_index][eINSERT_STORAGE])(handle[lib_index], storage_id, storage_type, storage_path, uid, &err_msg);
if (ret != 0) {
MS_DBG_ERR("error : %s [%s]", g_array_index(so_array, char*, lib_index), err_msg);
MS_SAFE_FREE(err_msg);
int (*svc_disconnect) (void * handle, char ** err_msg);
int (*svc_check_db) (void * handle, uid_t uid, char ** err_msg);
int (*svc_get_storage_id) (void * handle, const char *path, char *storage_id, uid_t uid, char ** err_msg);
-int (*svc_insert_storage) (void *handle, const char *storage_id, int storage_type, const char *storage_name, const char *storage_path, uid_t uid, char **err_msg);
+int (*svc_insert_storage) (void *handle, const char *storage_id, int storage_type, const char *storage_path, uid_t uid, char **err_msg);
int (*svc_update_storage) (void *handle, const char *storage_id, const char *storage_path, uid_t uid, char **err_msg);
int (*svc_set_storage_validity) (void * handle, const char *storage_id, int validity, uid_t uid, char **err_msg);
int (*svc_check_storage) (void * handle, const char *storage_id, char **storage_path, int *validity, uid_t uid, char **err_msg);
}
} else {
/* insert new storage */
- ret = svc_insert_storage(db_handle, block_info->mount_uuid, 1, NULL, block_info->mount_path, tzplatform_getuid(TZ_USER_NAME), &err_msg);
+ ret = svc_insert_storage(db_handle, block_info->mount_uuid, 1, block_info->mount_path, tzplatform_getuid(TZ_USER_NAME), &err_msg);
if (ret < 0)
printf("Error svc_insert_storage\n");
MS_DBG_WARN("init storage data in DB end");
} else {
/* there is no information of this storage in Media DB */
- ret = ms_insert_storage(handle, mount_uuid, NULL, mount_path, uid);
+ ret = ms_insert_storage(handle, mount_uuid, mount_path, uid);
if (ret != MS_MEDIA_ERR_NONE) {
MS_DBG_ERR("ms_insert_storage failed");
goto ERROR;
MS_DBG_ERR("ms_set_storage_scan_status failed");
} else {
/* there is no information of this storage in Media DB */
- ret = ms_insert_storage(handle, storage_id, NULL, mount_path, uid);
+ ret = ms_insert_storage(handle, storage_id, mount_path, uid);
}
} else {
MS_DBG_ERR("STORAGE ID IS NUILL");
MS_SAFE_FREE(device_uuid);
continue;
}
- ret = ms_insert_storage(handle, device_uuid, NULL, mounted_path, uid);
+ ret = ms_insert_storage(handle, device_uuid, mounted_path, uid);
scan_type = MS_SCAN_ALL;
storage_id = strdup(device_uuid);
} else {
/* there is no information of this storage in Media DB */
MS_DBG_WARN("insert storage %s", mounted_path);
- ret = ms_insert_storage(handle, storage_id, NULL, mounted_path, uid);
+ ret = ms_insert_storage(handle, storage_id, mounted_path, uid);
scan_type = MS_SCAN_ALL;
}
} else {
/* there is no information of this storage in Media DB */
MS_DBG_WARN("insert storage %s", mounted_path);
- ret = ms_insert_storage(handle, storage_id, NULL, mounted_path, uid);
+ ret = ms_insert_storage(handle, storage_id, mounted_path, uid);
scan_type = MS_SCAN_ALL;
}
}
MS_DBG_WARN("init storage data in DB end");
} else {
- ret = ms_insert_storage(handle, DATADISC_STORAGE_ID, NULL, mnt_path, uid);
+ ret = ms_insert_storage(handle, DATADISC_STORAGE_ID, mnt_path, uid);
if (ret != MS_MEDIA_ERR_NONE) {
MS_DBG_ERR("ms_insert_storage failed");
goto END;
MS_DBG_WARN("init storage data in DB end");
} else {
- ret = ms_insert_storage(handle, DATADISC_STORAGE_ID, NULL, mnt_path, uid);
+ ret = ms_insert_storage(handle, DATADISC_STORAGE_ID, mnt_path, uid);
if (ret != MS_MEDIA_ERR_NONE) {
MS_DBG_ERR("ms_insert_storage failed");
ms_unload_functions();
} else {
/* there is no information of this storage in Media DB */
MS_DBG_WARN("##[senior mode]insert storage %s", path);
- ret = ms_insert_storage(handle, storage_id, NULL, path, uid);
+ ret = ms_insert_storage(handle, storage_id, path, uid);
MS_DBG_WARN("##[senior mode]");
scan_type = MS_SCAN_ALL;
}
} else {
/* there is no information of this storage in Media DB */
MS_DBG_WARN("##[senior mode]insert storage %s", path);
- ret = ms_insert_storage(handle, storage_id, NULL, path, uid);
+ ret = ms_insert_storage(handle, storage_id, path, uid);
MS_DBG_WARN("##[senior mode]");
scan_type = MS_SCAN_ALL;
}