1
0
Fork 0
mirror of https://github.com/borgbackup/borg.git synced 2025-02-21 13:47:16 +00:00

Merge pull request #6220 from ThomasWaldmann/fix-intermediate-commits

fix intermediate commits, shall be at end of segment
This commit is contained in:
TW 2022-02-02 05:30:34 +01:00 committed by GitHub
commit 495c6bb977
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1634,7 +1634,7 @@ def write_delete(self, id, raise_full=False):
def write_commit(self, intermediate=False):
# Intermediate commits go directly into the current segment - this makes checking their validity more
# expensive, but is faster and reduces clobber. Final commits go into a new segment.
fd = self.get_write_fd(want_new=not intermediate)
fd = self.get_write_fd(want_new=not intermediate, no_new=intermediate)
if intermediate:
fd.sync()
header = self.header_no_crc_fmt.pack(self.header_fmt.size, TAG_COMMIT)