Skip to content

Commit

Permalink
Flush file before closing after write operation
Browse files Browse the repository at this point in the history
  • Loading branch information
sagiegurari committed Nov 11, 2020
1 parent 0f7827e commit c101678
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
## CHANGELOG

### v0.1.2 (2020-11-12)

* Flush file before closing after write operation.

### v0.1.1 (2020-11-07)

* Internal functions are now namespaced with _fsio prefix.
Expand Down
1 change: 1 addition & 0 deletions src/fsio.c
Original file line number Diff line number Diff line change
Expand Up @@ -158,6 +158,7 @@ bool _fsio_write_text_file(char *file, char *text, char *mode)
return(false);
}

fflush(fp);
fclose(fp);

return(true);
Expand Down

0 comments on commit c101678

Please sign in to comment.