From owner-freebsd-standards@FreeBSD.ORG Mon Mar 20 11:10:16 2006 Return-Path: X-Original-To: freebsd-standards@hub.freebsd.org Delivered-To: freebsd-standards@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 3FC9416A422 for ; Mon, 20 Mar 2006 11:10:16 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 9CF3A43D46 for ; Mon, 20 Mar 2006 11:10:15 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.4/8.13.4) with ESMTP id k2KBAFs6086038 for ; Mon, 20 Mar 2006 11:10:15 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.4/8.13.4/Submit) id k2KBAFZw086037; Mon, 20 Mar 2006 11:10:15 GMT (envelope-from gnats) Resent-Date: Mon, 20 Mar 2006 11:10:15 GMT Resent-Message-Id: <200603201110.k2KBAFZw086037@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-standards@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, Volker Stolz Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id A51F616A400 for ; Mon, 20 Mar 2006 11:07:30 +0000 (UTC) (envelope-from stolz@i2.informatik.rwth-aachen.de) Received: from atlas.informatik.rwth-aachen.de (atlas.informatik.RWTH-Aachen.DE [137.226.194.2]) by mx1.FreeBSD.org (Postfix) with ESMTP id 1338A43D48 for ; Mon, 20 Mar 2006 11:07:29 +0000 (GMT) (envelope-from stolz@i2.informatik.rwth-aachen.de) Received: from i2.informatik.rwth-aachen.de (menelaos.informatik.RWTH-Aachen.DE [137.226.194.73]) by atlas.informatik.rwth-aachen.de (8.12.10/8.12.10/SuSE Linux 0.7) with ESMTP id k2KB7SsY003862 for ; Mon, 20 Mar 2006 12:07:28 +0100 Received: (from stolz@localhost) by i2.informatik.rwth-aachen.de (8.13.4/8.13.4/Submit) id k2KB7n5w011208; Mon, 20 Mar 2006 12:07:49 +0100 (CET) (envelope-from stolz) Message-Id: <200603201107.k2KB7n5w011208@i2.informatik.rwth-aachen.de> Date: Mon, 20 Mar 2006 12:07:49 +0100 (CET) From: Volker Stolz To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: standards/94729: fcntl() throws undocumented ENOTTY X-BeenThere: freebsd-standards@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Standards compliance List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 20 Mar 2006 11:10:16 -0000 >Number: 94729 >Category: standards >Synopsis: fcntl() throws undocumented ENOTTY >Confidential: no >Severity: serious >Priority: low >Responsible: freebsd-standards >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Mon Mar 20 11:10:15 GMT 2006 >Closed-Date: >Last-Modified: >Originator: Volker Stolz >Release: FreeBSD 6.1-BETA3 i386 >Organization: Lehrstuhl für Informatik II; RWTH Aachen (c) Universität >Environment: System: FreeBSD menelaos.informatik.rwth-aachen.de 6.1-BETA3 FreeBSD 6.1-BETA3 #1: Mon Mar 13 10:45:03 CET 2006 root@menelaos.informatik.rwth-aachen.de:/usr/obj/usr/src/sys/MENELAOS i386 >Description: When trying to set non-blocking IO on e.g. /dev/null, ENOTTY is returned. This is neither documented in the FreeBSD man page nor behaviour covered by IEEE Std 1003.1-2001. >From browsing our bug-tracker, there seem to be several instances of third-party software (mostly in ports) which required FreeBSD-specific patches. I understand that the Posix-description doesn't give us an easy way out, but we should at least document this in our own man page. >How-To-Repeat: Run the program below, redirecting input from /dev/null: ./a.out Fix: Unknown; should at least be documented. Maybe setting O_NONBLOCK on /dev/null should not fail? --- fcntltest.c begins here --- #include #include void main() { if (fcntl(0,F_SETFL,O_NONBLOCK) != 0) perror("yikes!"); return 0; } --- fcntltest.c ends here --- >Release-Note: >Audit-Trail: >Unformatted: