mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-22 07:56:33 -05:00
Removes the --find-by-name, -N option. Now it automatically searches
by name if a file is not found searching by inode, automatically reassigning inodes in restored files
This commit is contained in:
parent
3a5ce4e522
commit
8eafeafcb6
11 changed files with 204 additions and 227 deletions
10
state.c
10
state.c
|
|
@ -1211,10 +1211,6 @@ static void state_read_text(struct snapraid_state* state, const char* path, STRE
|
|||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
/* ignore nanoseconds if asked to find by name */
|
||||
if (state->opt.force_by_name)
|
||||
v_mtime_nsec = STAT_NSEC_INVALID;
|
||||
|
||||
c = sgetc(f);
|
||||
} else {
|
||||
/* use a special value, meaning that we don't have this information */
|
||||
|
|
@ -2142,10 +2138,6 @@ static void state_read_binary(struct snapraid_state* state, const char* path, ST
|
|||
else
|
||||
--v_mtime_nsec;
|
||||
|
||||
/* ignore nanoseconds if asked to find by name */
|
||||
if (state->opt.force_by_name)
|
||||
v_mtime_nsec = STAT_NSEC_INVALID;
|
||||
|
||||
ret = sgetb64(f, &v_inode);
|
||||
if (ret < 0) {
|
||||
decoding_error(path, f);
|
||||
|
|
@ -3162,7 +3154,7 @@ void state_read(struct snapraid_state* state)
|
|||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
||||
/* go futher to check other content files */
|
||||
/* go further to check other content files */
|
||||
while (node) {
|
||||
char other_path[PATH_MAX];
|
||||
struct stat other_st;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue