mirror of https://github.com/borgbackup/borg.git
Merge pull request #1025 from ThomasWaldmann/remove-tabs
_chunker.c: remove tab characters
This commit is contained in:
commit
512e7ec18a
|
@ -184,9 +184,9 @@ chunker_fill(Chunker *c)
|
||||||
length = c->bytes_read - offset;
|
length = c->bytes_read - offset;
|
||||||
#if ( ( _XOPEN_SOURCE >= 600 || _POSIX_C_SOURCE >= 200112L ) && defined(POSIX_FADV_DONTNEED) )
|
#if ( ( _XOPEN_SOURCE >= 600 || _POSIX_C_SOURCE >= 200112L ) && defined(POSIX_FADV_DONTNEED) )
|
||||||
|
|
||||||
// Only do it once per run.
|
// Only do it once per run.
|
||||||
if (pagemask == 0)
|
if (pagemask == 0)
|
||||||
pagemask = getpagesize() - 1;
|
pagemask = getpagesize() - 1;
|
||||||
|
|
||||||
// We tell the OS that we do not need the data that we just have read any
|
// We tell the OS that we do not need the data that we just have read any
|
||||||
// more (that it maybe has in the cache). This avoids that we spoil the
|
// more (that it maybe has in the cache). This avoids that we spoil the
|
||||||
|
@ -207,7 +207,7 @@ chunker_fill(Chunker *c)
|
||||||
// fadvise. This will cancel the final page and is not part
|
// fadvise. This will cancel the final page and is not part
|
||||||
// of the above workaround.
|
// of the above workaround.
|
||||||
overshoot = 0;
|
overshoot = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
posix_fadvise(c->fh, offset & ~pagemask, length - overshoot, POSIX_FADV_DONTNEED);
|
posix_fadvise(c->fh, offset & ~pagemask, length - overshoot, POSIX_FADV_DONTNEED);
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in New Issue