commit: 0f8a3f532b8dd780586e5599cac884cc256452e5
parent: 4f5769cbb653d820bbd931ef854c0da6f037c797
author: Brian Callahan <bcallah@openbsd.org>
date: Sun, 30 Sep 2018 17:24:49 -0400
From upstream: export PWD and OLDPWD
3 files changed, 37 insertions(+), 38 deletions(-)
diff --git a/CVS/Entries b/CVS/Entries
@@ -1,46 +1,46 @@
/config.h/1.19/Tue Jan 16 02:21:56 2018//
/history.c/1.80/Tue Jan 16 02:21:56 2018//
-/main.c/1.92/Result of merge//
/io.c/1.36/Fri Jun 1 19:10:08 2018//
/tty.c/1.17/Fri Jun 1 19:10:08 2018//
-/CONTRIBUTORS/1.10/Sun Sep 23 17:58:57 2018//
-/LEGAL/1.2/Sun Sep 23 17:58:57 2018//
-/Makefile/1.39/Sun Sep 23 17:59:17 2018//
-/NOTES/1.16/Sun Sep 23 17:58:57 2018//
-/PROJECTS/1.9/Sun Sep 23 17:58:57 2018//
-/README/1.16/Sun Sep 23 17:59:17 2018//
-/alloc.c/1.19/Sun Sep 23 17:58:57 2018//
-/c_ksh.c/1.61/Sun Sep 23 17:58:57 2018//
-/c_sh.c/1.63/Sun Sep 23 17:58:57 2018//
/c_test.c/1.25/Sun Sep 23 17:58:57 2018//
-/c_test.h/1.4/Sun Sep 23 17:58:57 2018//
-/c_ulimit.c/1.28/Sun Sep 23 17:58:57 2018//
/edit.c/1.66/Sun Sep 23 17:59:17 2018//
-/edit.h/1.12/Sun Sep 23 17:59:17 2018//
/emacs.c/1.85/Result of merge//
/eval.c/1.63/Sun Sep 23 17:59:17 2018//
/exec.c/1.73/Sun Sep 23 17:58:57 2018//
-/expand.h/1.15/Sun Sep 23 17:58:57 2018//
-/expr.c/1.33/Sun Sep 23 17:58:57 2018//
-/jobs.c/1.60/Sun Sep 23 17:58:57 2018//
-/ksh.1/1.201/Sun Sep 23 17:59:17 2018//
-/lex.c/1.78/Sun Sep 23 17:58:57 2018//
-/lex.h/1.21/Sun Sep 23 17:58:57 2018//
-/mail.c/1.24/Sun Sep 23 17:59:17 2018//
/misc.c/1.70/Sun Sep 23 17:58:57 2018//
-/path.c/1.22/Sun Sep 23 17:58:57 2018//
-/sh.1/1.148/Sun Sep 23 17:58:57 2018//
/sh.h/1.73/Sun Sep 23 17:58:57 2018//
-/shf.c/1.33/Sun Sep 23 17:58:57 2018//
-/shf.h/1.8/Sun Sep 23 17:58:57 2018//
-/syn.c/1.39/Sun Sep 23 17:58:57 2018//
-/table.c/1.25/Sun Sep 23 17:58:57 2018//
-/table.h/1.15/Sun Sep 23 17:59:17 2018//
-/trap.c/1.32/Sun Sep 23 17:58:57 2018//
-/tree.c/1.34/Sun Sep 23 17:58:57 2018//
-/tree.h/1.12/Sun Sep 23 17:58:57 2018//
-/tty.h/1.6/Sun Sep 23 17:58:57 2018//
/var.c/1.70/Sun Sep 23 17:59:17 2018//
-/version.c/1.12/Sun Sep 23 17:58:57 2018//
-/vi.c/1.56/Sun Sep 23 17:58:57 2018//
+/CONTRIBUTORS/1.10/Sun Sep 30 21:23:15 2018//
+/LEGAL/1.2/Sun Sep 30 21:23:15 2018//
+/Makefile/1.39/Sun Sep 30 21:23:27 2018//
+/NOTES/1.16/Sun Sep 30 21:23:15 2018//
+/PROJECTS/1.9/Sun Sep 30 21:23:15 2018//
+/README/1.16/Sun Sep 30 21:23:27 2018//
+/alloc.c/1.19/Sun Sep 30 21:23:15 2018//
+/c_ksh.c/1.61/Sun Sep 30 21:23:15 2018//
+/c_sh.c/1.63/Sun Sep 30 21:23:15 2018//
+/c_test.h/1.4/Sun Sep 30 21:23:15 2018//
+/c_ulimit.c/1.28/Sun Sep 30 21:23:15 2018//
+/edit.h/1.12/Sun Sep 30 21:23:15 2018//
+/expand.h/1.15/Sun Sep 30 21:23:15 2018//
+/expr.c/1.33/Sun Sep 30 21:23:15 2018//
+/jobs.c/1.60/Sun Sep 30 21:23:15 2018//
+/ksh.1/1.201/Sun Sep 30 21:23:15 2018//
+/lex.c/1.78/Sun Sep 30 21:23:15 2018//
+/lex.h/1.21/Sun Sep 30 21:23:15 2018//
+/mail.c/1.24/Sun Sep 30 21:23:15 2018//
+/main.c/1.93/Result of merge//
+/path.c/1.22/Sun Sep 30 21:23:15 2018//
+/sh.1/1.149/Sun Sep 30 21:23:27 2018//
+/shf.c/1.33/Sun Sep 30 21:23:15 2018//
+/shf.h/1.8/Sun Sep 30 21:23:15 2018//
+/syn.c/1.39/Sun Sep 30 21:23:15 2018//
+/table.c/1.25/Sun Sep 30 21:23:15 2018//
+/table.h/1.15/Sun Sep 30 21:23:15 2018//
+/trap.c/1.32/Sun Sep 30 21:23:15 2018//
+/tree.c/1.34/Sun Sep 30 21:23:15 2018//
+/tree.h/1.12/Sun Sep 30 21:23:15 2018//
+/tty.h/1.6/Sun Sep 30 21:23:15 2018//
+/version.c/1.12/Sun Sep 30 21:23:15 2018//
+/vi.c/1.56/Sun Sep 30 21:23:15 2018//
D
diff --git a/main.c b/main.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: main.c,v 1.92 2018/05/18 13:25:20 benno Exp $ */
+/* $OpenBSD: main.c,v 1.93 2018/09/29 14:13:19 millert Exp $ */
/*
* startup, main loop, environments and error handling
@@ -81,7 +81,7 @@ static const char initsubs[] = "${PS2=> } ${PS3=#? } ${PS4=+ }";
static const char *initcoms [] = {
"typeset", "-r", "KSH_VERSION", NULL,
- "typeset", "-x", "SHELL", "PATH", "HOME", NULL,
+ "typeset", "-x", "SHELL", "PATH", "HOME", "PWD", "OLDPWD", NULL,
"typeset", "-ir", "PPID", NULL,
"typeset", "-i", "OPTIND=1", NULL,
"eval", "typeset -i RANDOM MAILCHECK=\"${MAILCHECK-600}\" SECONDS=\"${SECONDS-0}\" TMOUT=\"${TMOUT-0}\"", NULL,
diff --git a/sh.1 b/sh.1
@@ -1,4 +1,4 @@
-.\" $OpenBSD: sh.1,v 1.148 2018/03/31 14:58:19 anton Exp $
+.\" $OpenBSD: sh.1,v 1.149 2018/09/28 18:32:39 millert Exp $
.\"
.\" Copyright (c) 2015 Jason McIntyre <jmc@openbsd.org>
.\"
@@ -14,7 +14,7 @@
.\" ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
.\" OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
.\"
-.Dd $Mdocdate: March 31 2018 $
+.Dd $Mdocdate: September 28 2018 $
.Dt SH 1
.Os
.Sh NAME
@@ -2117,7 +2117,6 @@ The default is
.Sq +\ \& .
.It PWD
The absolute pathname to the current working directory.
-Assignments to this variable are ignored.
.El
.Sh ASYNCHRONOUS EVENTS
The following signals affect the execution of