mirror of
https://github.com/amadvance/snapraid.git
synced 2026-11-21 23:46:27 -05:00
Adds support for saving the content file in .gz format
This commit is contained in:
parent
b9849c82b9
commit
b31dbf7fff
9 changed files with 410 additions and 44 deletions
2
state.c
2
state.c
|
|
@ -2134,7 +2134,7 @@ void state_write(struct snapraid_state* state)
|
|||
/* Use the sequence fflush() -> fsync() -> fclose() -> rename() to ensure */
|
||||
/* than even in a system crash event we have one valid copy of the file. */
|
||||
|
||||
if (sflush(f) != 0) {
|
||||
if (sfinish(f) != 0) {
|
||||
fprintf(stderr, "Error writing the content file '%s', in flush(). %s.\n", serrorfile(f), strerror(errno));
|
||||
exit(EXIT_FAILURE);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue