From c38dfbf51af267491702bbf7a5f77cf96816a672 Mon Sep 17 00:00:00 2001 From: tg Date: Sat, 7 May 2011 00:24:35 +0000 Subject: [PATCH] fix problem #1 and a comment --- lex.c | 6 +----- tree.c | 4 ++-- 2 files changed, 3 insertions(+), 7 deletions(-) diff --git a/lex.c b/lex.c index 78b254a..2b530f1 100644 --- a/lex.c +++ b/lex.c @@ -22,7 +22,7 @@ #include "sh.h" -__RCSID("$MirOS: src/bin/mksh/lex.c,v 1.148 2011/05/05 00:04:57 tg Exp $"); +__RCSID("$MirOS: src/bin/mksh/lex.c,v 1.149 2011/05/07 00:24:34 tg Exp $"); /* * states while lexing word @@ -812,8 +812,6 @@ yylex(int cf) *wp++ = QCHAR; *wp++ = c; } - /* invoke quoting mode */ - Xstring(ws, wp)[0] = QCHAR; } else if (c == '$') { if ((c2 = getsc()) == '\'') { PUSH_STATE(SEQUOTE); @@ -828,8 +826,6 @@ yylex(int cf) sherestring_quoted: *wp++ = OQUOTE; ignore_backslash_newline++; - /* invoke quoting mode */ - Xstring(ws, wp)[0] = QCHAR; } else if (c == '"') { sherestring_dquoted: state = statep->type = SHEREDQUOTE; diff --git a/tree.c b/tree.c index b4db8fd..736e977 100644 --- a/tree.c +++ b/tree.c @@ -22,7 +22,7 @@ #include "sh.h" -__RCSID("$MirOS: src/bin/mksh/tree.c,v 1.47 2011/05/05 00:05:01 tg Exp $"); +__RCSID("$MirOS: src/bin/mksh/tree.c,v 1.48 2011/05/07 00:24:35 tg Exp $"); #define INDENT 8 @@ -197,7 +197,7 @@ ptree(struct op *t, int indent, struct shf *shf) while (*ioact != NULL) { struct ioword *iop = *ioact++; - /* heredoc is 0 when tracing (set -x) */ + /* heredoc is NULL when tracing (set -x) */ if ((iop->flag & (IOTYPE | IOHERESTR)) == IOHERE && iop->heredoc) { shf_putc('\n', shf);