Date: Thu, 22 Aug 1996 08:20:04 +0200 (IST) From: Eli Zaretskii To: fredex AT fcshome DOT stoneham DOT ma DOT us Cc: djgpp AT delorie DOT com Subject: Re: interrupting with ctrl-C In-Reply-To: <199608211633.MAA03385@fcshome.stoneham.ma.us> Message-Id: Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII On Wed, 21 Aug 1996 fredex AT fcshome DOT stoneham DOT ma DOT us wrote: > If you're using the open()/read()/write()/close() family, you should > also be able to dup() the file handle then close the duplicate, which > should cause that particular file to be flushed to disk. I'd expect this > to have a lower impact on system load than a sync() or fsync(), since it > deals with only this one file. `fsync' only commits a single file, so it's faster than `close', because `close' also does other things besides updating the disk. The only problem with `fsync' is portability: it isn't usually available with other DOS compilers (Unix does have it). However, it's very simple to write such a function: it's only a single DOS function call (Int 21h/AX=6800h).