int msc_stop_scan_thread(void);
int msc_get_remain_scan_request(ms_scan_type_e scan_type, int *remain_request);
int msc_get_dir_scan_status(bool *scan_status);
-int msc_set_cancel_path(const char *cancel_path);
#endif /*_MEDIA_SCANNER_SCAN_V2_H_*/
if (msc_get_dir_scan_status(&status) == MS_MEDIA_ERR_NONE) {
if (status == TRUE) {
- MS_DBG_WARN("Doing directory scanning. Set cancel path");
- msc_set_cancel_path(mount_path);
+ MS_DBG_WARN("Doing directory scanning");
}
status = FALSE;
}
gpointer current_data2 = NULL;
GMutex scan_item_mutex;
-char *g_cancel_path2;
char *g_blocked_path2;
s_scan_item* cancel_scan_item = NULL;
return MS_MEDIA_ERR_NONE;
}
-int msc_set_cancel_path(const char *cancel_path)
-{
- if (g_cancel_path2 != NULL) {
- MS_DBG_WARN("g_cancel_path2 is not NULL");
- MS_SAFE_FREE(g_cancel_path2);
- }
-
- g_cancel_path2 = strdup(cancel_path);
-
- return MS_MEDIA_ERR_NONE;
-}
-
gboolean msc_storage_scan_thread(void *data);
int msc_check_remain_task(void);
ms_db_status_type_t msc_check_scanning_status(void);
-int msc_set_cancel_path(const char *cancel_path);
int msc_del_cancel_path(void);
void msc_metadata_update_thread(ms_comm_msg_s *recv_msg);
int msc_init_scanner(void);
GAsyncQueue *scan_queue;
GAsyncQueue *reg_queue;
GMutex scan_req_mutex;
-char *g_cancel_path;
static int __msc_clear_file_list(GArray *path_array);
return false;
}
-int msc_set_cancel_path(const char *cancel_path)
-{
- if (g_cancel_path != NULL) {
- MS_DBG_WARN("g_cancel_path is not NULL");
- MS_SAFE_FREE(g_cancel_path);
- }
-
- g_cancel_path = strdup(cancel_path);
-
- return MS_MEDIA_ERR_NONE;
-}
-
static int __msc_dir_scan_meta_update(void **handle, const char*start_path, const char *storage_id, ms_storage_type_t storage_type, uid_t uid)
{
int ret = MS_MEDIA_ERR_NONE;
goto END_REMOVE_REQUEST;
}
- msc_set_cancel_path(recv_msg->msg);
-
temp_scan_queue = g_async_queue_new();
for (i = 0; i < len; i++) {