As per behaviour on SVR4 systems, to allow any desirable type of header in the
override, seperate by comma (',') only, rather than any type of whitespace (the literal space character (' ') had already been removed from this list). This allows things like: miamivice# ps -opid='Process > Identifier' Process Identifier 1350 1445 1450 To work.
This commit is contained in:
parent
8fe5b86833
commit
3afc0fe273
@ -235,14 +235,16 @@ parsefmt(const char *p)
|
||||
static struct varent *vtail;
|
||||
char *tempstr, *tempstr1;
|
||||
|
||||
#define FMTSEP "\t,\n"
|
||||
tempstr1 = tempstr = strdup(p);
|
||||
while (tempstr && *tempstr) {
|
||||
char *cp;
|
||||
VAR *v;
|
||||
struct varent *vent;
|
||||
|
||||
while ((cp = strsep(&tempstr, FMTSEP)) != NULL && *cp == '\0')
|
||||
/*
|
||||
* Seperate the format by commas.
|
||||
*/
|
||||
while ((cp = strsep(&tempstr, ",")) != NULL && *cp == '\0')
|
||||
/* void */;
|
||||
if (cp == NULL || !(v = findvar(cp)))
|
||||
continue;
|
||||
|
Loading…
x
Reference in New Issue
Block a user