diff options
author | Theo de Raadt <deraadt@cvs.openbsd.org> | 1996-05-21 21:13:05 +0000 |
---|---|---|
committer | Theo de Raadt <deraadt@cvs.openbsd.org> | 1996-05-21 21:13:05 +0000 |
commit | 1122d62a799cab0f1666caf090d1a64a2ea5e6e0 (patch) | |
tree | e245b05ea74210924d63cebb1dad300c1ae465bf /bin/sh | |
parent | 587bbce14a6cbe8219c2f1f6e8ea448e41f56a0e (diff) |
do newline correct inside ``, netbsd pr#2384
Diffstat (limited to 'bin/sh')
-rw-r--r-- | bin/sh/parser.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/bin/sh/parser.c b/bin/sh/parser.c index 41eed597ee3..06ab737ecd7 100644 --- a/bin/sh/parser.c +++ b/bin/sh/parser.c @@ -1,5 +1,5 @@ -/* $OpenBSD: parser.c,v 1.3 1996/03/08 22:01:03 niklas Exp $ */ -/* $NetBSD: parser.c,v 1.28 1996/03/05 21:04:00 christos Exp $ */ +/* $OpenBSD: parser.c,v 1.4 1996/05/21 21:13:04 deraadt Exp $ */ +/* $NetBSD: parser.c,v 1.29 1996/05/09 19:40:08 christos Exp $ */ /*- * Copyright (c) 1991, 1993 @@ -41,7 +41,7 @@ #if 0 static char sccsid[] = "@(#)parser.c 8.7 (Berkeley) 5/16/95"; #else -static char rcsid[] = "$NetBSD: parser.c,v 1.28 1996/03/05 21:04:00 christos Exp $"; +static char rcsid[] = "$NetBSD: parser.c,v 1.29 1996/05/09 19:40:08 christos Exp $"; #endif #endif /* not lint */ @@ -1281,6 +1281,13 @@ parsebackq: { setprompt(2); else setprompt(0); + /* + * If eating a newline, avoid putting + * the newline into the new character + * stream (via the STPUTC after the + * switch). + */ + continue; } if (c != '\\' && c != '`' && c != '$' && (!dblquote || c != '"')) |