Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!ncar!ico!ism780c!haddock!karl From: karl@haddock.ima.isc.com (Karl Heuer) Newsgroups: comp.lang.c Subject: Re: When to use fflush()? Keywords: fflush Message-ID: <14507@haddock.ima.isc.com> Date: 1 Sep 89 22:48:54 GMT References: <143@sherpa.uucp> <10882@smoke.BRL.MIL> Reply-To: karl@haddock.ima.isc.com (Karl Heuer) Organization: Interactive Systems, Cambridge, MA 02138-5302 Lines: 11 In article <10882@smoke.BRL.MIL> gwyn@brl.arpa (Doug Gwyn) writes: >Use fflush() whenever you want to make sure that the buffers are forced out. I've forgotten whether this issue was ever resolved: what should happen if the output stream is a VMS record-oriented file? If the currently buffered output contains no newlines, is it appropriate for fflush() to do nothing, and return success? Karl W. Z. Heuer (ima!haddock!karl or karl@haddock.isc.com), The Walking Lint (The problem is that, if I'm not mistaken, a `line' in such a file consists of a record with a byte-count prefix, and no actual newline character.)