From owner-freebsd-hackers Tue Dec 9 16:28:19 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.7/8.8.7) id QAA22751 for hackers-outgoing; Tue, 9 Dec 1997 16:28:19 -0800 (PST) (envelope-from owner-freebsd-hackers) Received: from sax.sax.de (sax.sax.de [193.175.26.33]) by hub.freebsd.org (8.8.7/8.8.7) with ESMTP id QAA22705 for ; Tue, 9 Dec 1997 16:28:10 -0800 (PST) (envelope-from j@uriah.heep.sax.de) Received: (from uucp@localhost) by sax.sax.de (8.8.8/8.8.8) with UUCP id BAA01922 for freebsd-hackers@freebsd.org; Wed, 10 Dec 1997 01:28:04 +0100 (CET) (envelope-from j@uriah.heep.sax.de) Received: (from j@localhost) by uriah.heep.sax.de (8.8.8/8.8.5) id AAA04799; Wed, 10 Dec 1997 00:59:18 +0100 (MET) Date: Wed, 10 Dec 1997 00:59:18 +0100 (MET) Message-Id: <199712092359.AAA04799@uriah.heep.sax.de> Mime-Version: 1.0 X-Newsreader: knews 0.9.8 Reply-To: joerg_wunsch@uriah.heep.sax.de (Joerg Wunsch) Organization: Private BSD site, Dresden X-Phone: +49-351-2012 669 X-PGP-Fingerprint: DC 47 E6 E4 FF A6 E9 8F 93 21 E0 7D F9 12 D6 4E References: <199712061054.LAA25661@labinfo.iet.unipi.it> From: j@uriah.heep.sax.de (J Wunsch) Subject: Re: Why FIONREAD has no dual for write ? X-Original-Newsgroups: local.freebsd.hackers To: freebsd-hackers@freebsd.org Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-hackers@freebsd.org X-Loop: FreeBSD.org Precedence: bulk Luigi Rizzo wrote: > There is no FIONWRITE call (how many bytes you can write before > blocking) which would be nice to have, instead of having to resort to > non-blocking writes. I think estimating this number is much harder than FIONREAD: for the read case, you do already know how much you've got. For the write case, you can only estimate, but perhaps have to predict a lot of potential allocation policy (the implementation might chose to allocate more buffer space for some reason). I get your point though, the above is just guessing... -- cheers, J"org joerg_wunsch@uriah.heep.sax.de -- http://www.sax.de/~joerg/ -- NIC: JW11-RIPE Never trust an operating system you don't have sources for. ;-)