From owner-freebsd-bugs@FreeBSD.ORG Wed Feb 23 21:24:52 2011 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 468671065672; Wed, 23 Feb 2011 21:24:52 +0000 (UTC) (envelope-from arundel@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 1D07D8FC15; Wed, 23 Feb 2011 21:24:52 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.4/8.14.4) with ESMTP id p1NLOpB0099458; Wed, 23 Feb 2011 21:24:52 GMT (envelope-from arundel@freefall.freebsd.org) Received: (from arundel@localhost) by freefall.freebsd.org (8.14.4/8.14.4/Submit) id p1NLOpIQ099454; Wed, 23 Feb 2011 21:24:51 GMT (envelope-from arundel) Date: Wed, 23 Feb 2011 21:24:51 GMT Message-Id: <201102232124.p1NLOpIQ099454@freefall.freebsd.org> To: svartman95@gmail.com, arundel@FreeBSD.org, freebsd-bugs@FreeBSD.org From: arundel@FreeBSD.org Cc: Subject: Re: bin/154983: head(1) returns EXIT_SUCCESS upon EOF X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 23 Feb 2011 21:24:52 -0000 Synopsis: head(1) returns EXIT_SUCCESS upon EOF State-Changed-From-To: open->closed State-Changed-By: arundel State-Changed-When: Wed Feb 23 21:22:24 UTC 2011 State-Changed-Why: I'm afraid your assumption is wrong. The POSIX specs [1] clearly state that "When a file contains less than number lines, it shall be copied to standard output in its entirety. This shall not be an error." [1] http://pubs.opengroup.org/onlinepubs/9699919799/ http://www.freebsd.org/cgi/query-pr.cgi?pr=154983