about summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog6
-rw-r--r--Src/parse.c2
2 files changed, 8 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 671afac4e..701b9a0ae 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,9 @@
+2002-06-02  Peter Stephenson  <pws@pwstephenson.fsnet.co.uk>
+
+	* ?????: Src/parse.c: `outer() { inner(); }' succeded; when outer
+	ran it created a bogus `inner' which crashed the shell.  Make
+	original command issue error.
+
 2002-05-31  Clint Adams  <clint@zsh.org>
 
         * unposted: zshconfig.ac: get rid of evil -Wno-implicit
diff --git a/Src/parse.c b/Src/parse.c
index 7da0667a5..542a9791b 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -1566,6 +1566,8 @@ par_simple(int *complex, int nr)
 		pl = ecadd(WCB_PIPE(WC_PIPE_END, 0));
 
 		par_cmd(&c);
+		if (!c)
+		    YYERROR(oecused);
 
 		set_sublist_code(sl, WC_SUBLIST_END, 0, ecused - 1 - sl, c);
 		set_list_code(ll, (Z_SYNC | Z_END), c);