NetBSD Problem Report #263

From gnats  Tue May 24 17:07:45 1994
Received: from forte (forte.mathematik.uni-Bremen.de [134.102.232.1]) by sun-lamp.cs.berkeley.edu (8.6.9/8.6.9) with ESMTP id RAA02018 for <gnats-bugs@sun-lamp.cs.berkeley.edu>; Tue, 24 May 1994 17:07:21 -0700
Message-Id: <199405250006.CAA14888@forte>
Date: Wed, 25 May 1994 02:06:35 +0200
From: thomas@mathematik.uni-Bremen.de
Reply-To: thomas@mathematik.uni-Bremen.de
To: gnats-bugs@sun-lamp.cs.berkeley.edu
Subject: test -t doesn't work as advertised
X-Send-Pr-Version: 3.2

>Number:         263
>Category:       bin
>Synopsis:       test -t doesn't work as advertised
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    gnats-admin
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue May 24 17:20:01 +0000 1994
>Closed-Date:    Wed Jun 29 15:13:05 +0000 1994
>Last-Modified:  
>Originator:     Thomas Eberhardt
>Release:        
>Organization:
CeVis, University of Bremen, Germany
>Environment:

System: NetBSD ed209 NetBSD 0.9B NetBSD 0.9B (ED209) #0: Fri May 20 21:20:05 MET DST 1994 thomas@ed209:/usr/src/sys/arch/i386/compile/ED209 i386

Machine: i386
>Description:
	The file descriptor argument to test -t isn't optional any more.
	It was a few weeks ago.  This breaks, for example, zmore.

>How-To-Repeat:
	% test -t
	test: syntax error
>Fix:

>Release-Note:
>Audit-Trail:

From: "J.T. Conklin" <jtc>
To: GNATS administrator <gnats-admin>
Subject: Re: bin/263: test -t doesn't work as advertised
Date: Sun, 29 May 1994 20:44:40 -0700


 	`J.T. Conklin' made changes to this PR.

 --- /var/tmp/gnats016245	Sun May 29 20:43:59 1994
 +++ /var/tmp/gnatsa16245	Sun May 29 20:44:24 1994
 @@ -13,7 +13,7 @@
  >Category:       bin
  >Synopsis:       test -t doesn't work as advertised
  >Confidential:   no
 ->Severity:       serious
 +>Severity:       critical
  >Priority:       medium
  >Responsible:    gnats-admin
  >State:          open

State-Changed-From-To: open->closed
State-Changed-By: jtc
State-Changed-When: Wed Jun 29 15:13:05 1994
State-Changed-Why:
I've reverted to the previous behavior.  

Code had been added that checked to see if a single argument was a
unary operator.  This turns out to violate POSIX.2, as it defines
special cases for 1, 2, 3, and 4 arguments to eliminate grammar
ambiguity.

Please note that although "test -t" will no longer cause a syntax
error, it doesn't mean what it used to.  As of POSIX.2, the -t
primary's file_descriptor argument is no longer optional.


>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.