diff --git a/src/cmd/plumb/rules.c b/src/cmd/plumb/rules.c index 6e9b2c63..2cb4afe9 100644 --- a/src/cmd/plumb/rules.c +++ b/src/cmd/plumb/rules.c @@ -289,22 +289,35 @@ dollar(Exec *e, char *s, int *namelen) return variable(s, n); } +static void +ruleerror(char *msg) +{ + if(parsing){ + parsing = 0; + parseerror("%s", msg); + } + error("%s", msg); +} + /* expand one blank-terminated string, processing quotes and $ signs */ char* expand(Exec *e, char *s, char **ends) { char *p, *ep, *val; - int namelen, quoting; + int namelen, vallen, quoting, inputleft; p = ebuf; ep = ebuf+sizeof ebuf-1; quoting = 0; - while(p