From mboxrd@z Thu Jan 1 00:00:00 1970 X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: 10b612,a8c6b03ff0f3bde6 X-Google-Attributes: gid10b612,public X-Google-Thread: 1014db,a8c6b03ff0f3bde6 X-Google-Attributes: gid1014db,public X-Google-Thread: fee84,a8c6b03ff0f3bde6 X-Google-Attributes: gidfee84,public X-Google-Thread: f678f,a8c6b03ff0f3bde6 X-Google-Attributes: gidf678f,public From: al012@svtstu.seqeb.gov.au (Anthony Lee) Subject: (Summary of response) Re: File descriptor equivalent of fflush? Date: 1996/01/29 Message-ID: #1/1 X-Deja-AN: 137083636 sender: news@un.seqeb.gov.au (USENET News System) x-nntp-posting-host: 147.209.150.100 references: organization: Your Organization mime-version: 1.0 newsgroups: comp.lang.c,comp.unix.osf.misc,comp.unix.osf.osf1,comp.unix.ultrix In article , al012@svtstu.seqeb.gov.au says... > >Dear all, > >I am trying to find an equivalent of fflush for file descriptors >in ULTRIX and OSF. > Many thanks to all those people who send me replies. Two people told me that I don't need to flush because read and write are not buffered. But then the man pages for write on ULTRIX had this >By default, write does asynchronous writes. That is, after the data is >written to a buffer cache, control returns to the program. The actual >write to a device takes place after control returns. However, if you >use an open or fcntl call to open a file for synchronous writes, control >does not return to the program until after the buffer cache has been >written to the device. Several people suggested that I use fsync but be aware that on ULTRIX fsync will flush all buffers. -- Anthony Lee These are my opinions and not SEQEB. SEQEB 150 Charlotte Street ..-- __o Brisbane ....-- _ \<,_ Qld 4000 ____ (_)/ (_) Australia voice:+61 7 3407 4541 Death to the Daleks!!!! fax: +61 7 3407 4607 email: AL012@svtstu.seqeb.gov.au