is_recursive = (scan_type == MS_MSG_DIRECTORY_SCANNING_NON_RECURSIVE) ? false : true;
- /* folder validity set 0 under the start_path in folder table*/
- if (ms_set_folder_validity(handle, storage_id, new_start_path, MS_INVALID, is_recursive, uid) != MS_MEDIA_ERR_NONE)
- MS_DBG_ERR("set_folder_validity failed [%d] ", scan_type);
+ /* fix timing issue, folder uuid of start path mismatch in folder and media table*/
+ /*if (ms_set_folder_validity(handle, storage_id, new_start_path, MS_INVALID, is_recursive, uid) != MS_MEDIA_ERR_NONE)
+ MS_DBG_ERR("set_folder_validity failed [%d] ", scan_type);*/
if (g_file_test(new_start_path, G_FILE_TEST_IS_DIR)) {
if (ms_insert_folder(handle, storage_id, new_start_path, uid) != MS_MEDIA_ERR_NONE)
if (scan_status == MS_DIR_SCAN_DONE) {
/* do nothing */
MS_DBG_WARN("[%s] scan done", scan_data->msg);
- err = ms_set_folder_item_validity(handle, storage_id, scan_data->msg, MS_VALIND, MS_NON_RECURSIVE, uid);
+ /*fix timing issue, deleted items scanned by storage scan is set validity 1 again*/
+ /*err = ms_set_folder_item_validity(handle, storage_id, scan_data->msg, MS_VALIND, MS_NON_RECURSIVE, uid);*/
goto SCAN_DONE;
} else if (scan_status == MS_DIR_SCAN_PROCESSING) {
MS_DBG_WARN("[%s] scanning, waiting...", scan_data->msg);