summary refs log tree commit diff
path: root/Src
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-14 09:26:55 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-06-14 09:26:55 +0000
commit5f81bbc8695db820a2a1996b63cc8ec3b9a902e6 (patch)
tree3172c05313ef0811bf86c84f0e0bb7ab7896f1f5 /Src
parent53f5cc9465c0a0d3b7ae125a318fb8a0b7373908 (diff)
downloadzsh-5f81bbc8695db820a2a1996b63cc8ec3b9a902e6.tar.gz
zsh-5f81bbc8695db820a2a1996b63cc8ec3b9a902e6.tar.xz
zsh-5f81bbc8695db820a2a1996b63cc8ec3b9a902e6.zip
nix kaboom with `time time' (?)
Diffstat (limited to 'Src')
-rw-r--r--Src/parse.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/Src/parse.c b/Src/parse.c
index 5e90984ac..4f79b2e4b 100644
--- a/Src/parse.c
+++ b/Src/parse.c
@@ -799,10 +799,6 @@ par_cmd(int *complex)
 	par_funcdef();
 	cmdpop();
 	break;
-    case TIME:
-	*complex = 1;
-	par_time();
-	break;
     case DINBRACK:
 	cmdpush(CS_COND);
 	par_dinbrack();
@@ -813,6 +809,20 @@ par_cmd(int *complex)
 	ecstr(tokstr);
 	yylex();
 	break;
+    case TIME:
+	{
+	    static int inpartime = 0;
+
+	    if (!inpartime) {
+		*complex = 1;
+		inpartime = 1;
+		par_time();
+		inpartime = 0;
+		break;
+	    }
+	}
+	tok = STRING;
+	/* fall through */
     default:
 	{
 	    int sr;