From owner-freebsd-bugs Tue Aug 24 19:51:24 1999 Delivered-To: freebsd-bugs@freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.ORG [204.216.27.21]) by hub.freebsd.org (Postfix) with ESMTP id 1EF5F150DC for ; Tue, 24 Aug 1999 19:51:09 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.9.3/8.9.2) id TAA59206; Tue, 24 Aug 1999 19:50:01 -0700 (PDT) (envelope-from gnats@FreeBSD.org) Received: from po4.wam.umd.edu (po4.wam.umd.edu [128.8.10.166]) by hub.freebsd.org (Postfix) with ESMTP id A140F15193 for ; Tue, 24 Aug 1999 19:44:09 -0700 (PDT) (envelope-from howardjp@wam.umd.edu) Received: from rac9.wam.umd.edu (root@rac9.wam.umd.edu [128.8.10.149]) by po4.wam.umd.edu (8.9.3/8.9.3) with ESMTP id WAA08761 for ; Tue, 24 Aug 1999 22:42:10 -0400 (EDT) Received: from rac9.wam.umd.edu (sendmail@localhost [127.0.0.1]) by rac9.wam.umd.edu (8.9.3/8.9.3) with SMTP id WAA07658 for ; Tue, 24 Aug 1999 22:42:09 -0400 (EDT) Received: (from howardjp@localhost) by rac9.wam.umd.edu (8.9.3/8.9.3) id WAA07653 for FreeBSD-gnats-submit@freebsd.org; Tue, 24 Aug 1999 22:42:09 -0400 (EDT) Message-Id: <199908250242.WAA07653@rac9.wam.umd.edu> Date: Tue, 24 Aug 1999 22:42:09 -0400 (EDT) From: James Howard Reply-To: howardjp@wam.umd.edu To: FreeBSD-gnats-submit@freebsd.org X-Send-Pr-Version: 3.2 Subject: bin/13363: Patch to env(1) for Unix 98 compatability Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org >Number: 13363 >Category: bin >Synopsis: Patch to env(1) for Unix 98 compatability >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Tue Aug 24 19:50:00 PDT 1999 >Closed-Date: >Last-Modified: >Originator: James Howard >Release: FreeBSD 3.2-STABLE i386 >Organization: University of Maryland >Environment: FreeBSD byzantine 3.2-STABLE FreeBSD 3.2-STABLE #5: Sat Aug 7 23:43:54 GMT 1999 root@byzantine:/usr/src/sys/compile/BYZANTINE i386 >Description: Unix 98 requires that env(1) take the option -i to destroy the inherited environment. This would be identical to the currently existing - option. This diff adds a fallthrough so that -i is handled as Unix 98 specifies. This does not include a change for the man page, I did not think it was necessary. >How-To-Repeat: env -i gives error about illegal option >Fix: *** /usr/src/usr.bin/env/env.c Sun Dec 6 22:58:22 1998 --- /usr/local/src/env/env.c Tue Aug 24 20:33:03 1999 *************** *** 60,67 **** char *cleanenv[1]; int ch; ! while ((ch = getopt(argc, argv, "-")) != -1) switch(ch) { case '-': environ = cleanenv; cleanenv[0] = NULL; --- 60,72 ---- char *cleanenv[1]; int ch; ! while ((ch = getopt(argc, argv, "i-")) != -1) switch(ch) { + case 'i': + /* + * For Unix 98 compatability. + */ + /* FALLTHROUGH */ case '-': environ = cleanenv; cleanenv[0] = NULL; >Release-Note: >Audit-Trail: >Unformatted: To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-bugs" in the body of the message