Sorts the files by physical address before inserting them for the first time.

This commit is contained in:
Andrea Mazzoleni 2013-06-25 22:41:10 +02:00
parent e0164b29d1
commit 6032576650
12 changed files with 245 additions and 18 deletions

View file

@ -1017,7 +1017,7 @@ static int state_check_process(struct snapraid_state* state, int check, int fix,
inode = handle[j].st.st_ino;
/* search for the corresponding inode */
collide_file = tommy_hashdyn_search(&handle[j].disk->inodeset, file_inode_compare, &inode, file_inode_hash(inode));
collide_file = tommy_hashdyn_search(&handle[j].disk->inodeset, file_inode_compare_to_arg, &inode, file_inode_hash(inode));
/* if the inode is already in the database and it refers at a different file name, */
/* we can fix the file time ONLY if the time and size allow to differentiates */