aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/os
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/os')
-rw-r--r--src/nvim/os/fs.c1
-rw-r--r--src/nvim/os/signal.c2
2 files changed, 2 insertions, 1 deletions
diff --git a/src/nvim/os/fs.c b/src/nvim/os/fs.c
index 0414794d01..3e1af7f1c2 100644
--- a/src/nvim/os/fs.c
+++ b/src/nvim/os/fs.c
@@ -629,6 +629,7 @@ int os_fsync(int fd)
{
int r;
RUN_UV_FS_FUNC(r, uv_fs_fsync, fd, NULL);
+ g_stats.fsync++;
return r;
}
diff --git a/src/nvim/os/signal.c b/src/nvim/os/signal.c
index 732be072e1..fc7f9cefd1 100644
--- a/src/nvim/os/signal.c
+++ b/src/nvim/os/signal.c
@@ -145,7 +145,7 @@ static void on_signal(SignalWatcher *handle, int signum, void *data)
case SIGPWR:
// Signal of a power failure(eg batteries low), flush the swap files to
// be safe
- ml_sync_all(false, false);
+ ml_sync_all(false, false, true);
break;
#endif
#ifdef SIGPIPE