Deutsch   English   Français   Italiano  
<v5t6s0$1ub$2@gal.iecc.com>

View for Bookmarking (what is this?)
Look up another Usenet article

Path: ...!news.iecc.com!.POSTED.news.iecc.com!not-for-mail
From: John Levine <johnl@taugh.com>
Newsgroups: comp.arch
Subject: Re: streams and file locks, ancient OS history
Date: Mon, 1 Jul 2024 03:13:04 -0000 (UTC)
Organization: Taughannock Networks
Message-ID: <v5t6s0$1ub$2@gal.iecc.com>
References: <s7r87j1c3u6mim0db3ccbdvknvtjr4anu3@4ax.com> <2024Jun30.183810@mips.complang.tuwien.ac.at> <v5s6rc$22gn$1@gal.iecc.com> <v5t00n$ombn$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 1 Jul 2024 03:13:04 -0000 (UTC)
Injection-Info: gal.iecc.com; posting-host="news.iecc.com:2001:470:1f07:1126:0:676f:7373:6970";
	logging-data="1995"; mail-complaints-to="abuse@iecc.com"
In-Reply-To: <s7r87j1c3u6mim0db3ccbdvknvtjr4anu3@4ax.com> <2024Jun30.183810@mips.complang.tuwien.ac.at> <v5s6rc$22gn$1@gal.iecc.com> <v5t00n$ombn$1@dont-email.me>
Cleverness: some
X-Newsreader: trn 4.0-test77 (Sep 1, 2010)
Originator: johnl@iecc.com (John Levine)
Bytes: 1912
Lines: 17

t appears that Lawrence D'Oliveiro  <ldo@nz.invalid> said:
>On Sun, 30 Jun 2024 18:06:36 -0000 (UTC), John Levine wrote:
>
>> Squinting at the source code for FreeBSD's stdio, it only flushes writes
>> when it fills the buffer or when it writes a \n character with the '\n'
>> hard coded in the source code.
>
>Both POSIX and C specs require this to be configurable
><https://manpages.debian.org/3/setbuf.3.en.html>.

I looked at more of the code and it seems to do the right thing in
lower level routines. But the point stands, if you want to have
multiple programs writing into the same file, they all need to have
matching locking and buffering.
-- 
Regards,
John Levine, johnl@taugh.com, Primary Perpetrator of "The Internet for Dummies",
Please consider the environment before reading this e-mail. https://jl.ly