elks-enhanced

publicRead
Owner: themasterBranch: masterCommits: 6893Updated: 2026-04-19 00:15
Git CLI clone URL
git clone https://www.xt-emporium.com/git/elks-enhanced.git
Fullscreen desktop URL

Commit diff

Commit 141265822ddd487c91afdddd93edfe5135ec97c
commit 141265822ddd487c91afdddd93edfe5135ec97c3
Author: Greg Haerr <greg@censoft.com>
Date:   Sun Feb 8 19:02:37 2026 -0700

    [cmds] Always sync buffers to disk before fsync exit
---
 elkscmd/disk_utils/fsck.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/elkscmd/disk_utils/fsck.c b/elkscmd/disk_utils/fsck.c
index 39403e6d..b7fd2aca 100644
--- a/elkscmd/disk_utils/fsck.c
+++ b/elkscmd/disk_utils/fsck.c
@@ -1003,12 +1003,13 @@ int main(int argc, char ** argv)
 		printf(	"----------------------------\n"
 			"FILE SYSTEM HAS BEEN CHANGED\n"
 			"----------------------------\n");
-		for (count=0 ; count<3 ; count++)
-			sync();
 	}
 	else if (repair)
 		write_super_block();
 
+	for (count=0 ; count<3 ; count++)
+		sync();
+
 	if (repair && !automatic)
 		tcsetattr(0,TCSANOW,&termios);