freebsd-ports/editors/led/files/patch-src::file.c
Maxim Sobolev 4595219ad6 Issue fflush()->fsync() after saving file to the disk, so that the user will
not get zero-sized file after reboot if the system crashed shortly after the
save, as it usually the case when you are hacking some potential panic(9)
implementation (e.g. kernel module). Bump PORTREVISION.
2002-04-29 23:25:30 +00:00

13 lines
183 B
C

$FreeBSD$
--- src/file.c.orig Sun Jun 10 06:44:19 2001
+++ src/file.c Tue Apr 30 02:15:40 2002
@@ -148,4 +148,6 @@
curr = curr->next;
}
+ fflush(fp);
+ fsync(fileno(fp));
}