mirror of
https://github.com/amadvance/snapraid.git
synced 2026-12-03 05:10:16 -05:00
Detect and auto-heal content replicas left at different publication generations
This commit is contained in:
parent
74647cda14
commit
5e4cca1fe3
3 changed files with 124 additions and 64 deletions
|
|
@ -862,3 +862,20 @@ int ssync(STREAM* s)
|
|||
}
|
||||
#endif
|
||||
|
||||
int smtime(STREAM* s, int64_t mtime_sec, int mtime_nsec)
|
||||
{
|
||||
unsigned i;
|
||||
|
||||
for (i = 0; i < s->handle_size; ++i) {
|
||||
if (s->handle[i].f != -1 && fmtime(s->handle[i].f, mtime_sec, mtime_nsec) != 0) {
|
||||
/* LCOV_EXCL_START */
|
||||
s->state = STREAM_STATE_ERROR;
|
||||
s->state_index = i;
|
||||
return -1;
|
||||
/* LCOV_EXCL_STOP */
|
||||
}
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue