Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/bin/sh allow case statement without any patterns.
details: https://anonhg.NetBSD.org/src/rev/4d3df72fdbad
branches: trunk
changeset: 325616:4d3df72fdbad
user: christos <christos%NetBSD.org@localhost>
date: Tue Dec 31 22:53:57 2013 +0000
description:
allow case statement without any patterns.
diffstat:
bin/sh/parser.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diffs (36 lines):
diff -r fd6ceebfb732 -r 4d3df72fdbad bin/sh/parser.c
--- a/bin/sh/parser.c Tue Dec 31 21:37:01 2013 +0000
+++ b/bin/sh/parser.c Tue Dec 31 22:53:57 2013 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: parser.c,v 1.85 2013/10/02 21:48:55 christos Exp $ */
+/* $NetBSD: parser.c,v 1.86 2013/12/31 22:53:57 christos Exp $ */
/*-
* Copyright (c) 1991, 1993
@@ -37,7 +37,7 @@
#if 0
static char sccsid[] = "@(#)parser.c 8.7 (Berkeley) 5/16/95";
#else
-__RCSID("$NetBSD: parser.c,v 1.85 2013/10/02 21:48:55 christos Exp $");
+__RCSID("$NetBSD: parser.c,v 1.86 2013/12/31 22:53:57 christos Exp $");
#endif
#endif /* not lint */
@@ -432,7 +432,7 @@
cpp = &n1->ncase.cases;
noalias = 1;
checkkwd = 2, readtoken();
- do {
+ while(lasttoken != TESAC) {
*cpp = cp = (union node *)stalloc(sizeof (struct nclist));
if (lasttoken == TLP)
readtoken();
@@ -467,7 +467,7 @@
}
}
cpp = &cp->nclist.next;
- } while(lasttoken != TESAC);
+ }
noalias = 0;
*cpp = NULL;
checkkwd = 1;
Home |
Main Index |
Thread Index |
Old Index