diff options
| author | Byron Rakitzis <byron@archone.tamu.edu> | 1994-03-07 00:00:01 +0000 |
|---|---|---|
| committer | Toby Goodwin <toby@paccrat.org> | 2015-05-16 21:22:09 +0100 |
| commit | a076248389c82276e079756bee26c011b03f70f2 (patch) | |
| tree | 9d22c48c75bcd778f30cbb2e37b6dff6abb4f1d2 /history/history.c | |
| parent | 6bb38f6a01dbf4bbd584e038ceace0a00faa27bb (diff) | |
beta: rc-1.5betadev1
Diffstat (limited to 'history/history.c')
| -rw-r--r-- | history/history.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/history/history.c b/history/history.c index 5f2cece..e6aa29d 100644 --- a/history/history.c +++ b/history/history.c @@ -246,7 +246,7 @@ again: s = last; /* * if the command contains the "me" character at the start of the line - * or after any of [`{|()] then try again + * or after any of [`{|()@] then try again */ for (t = s; *t != '\0'; t++) @@ -254,8 +254,16 @@ again: s = last; char *u = t - 1; while (u >= s && (*u == ' ' || *u == '\t')) --u; - if (u < s || *u == '`' || *u == '{' || *u == '|' || *u == '(' || *u == ')') + if (u < s) goto again; + switch (*u) { + case '`': case '@': + case '(': case ')': + case '{': case '|': + goto again; + default: + break; + } } return s; } |