search for: varflags

Displaying 16 results from an estimated 16 matches for "varflags".

Did you mean: arflags
2019 Jan 25
0
[klibc:update-dash] [EXPAND] Optimise nulonly away and just use quoted as before
...------ 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/usr/dash/expand.c b/usr/dash/expand.c index 9bbd19da..a2f99f14 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -722,7 +722,6 @@ evalvar(char *p, int flag) ssize_t varlen; int easy; int quoted; - int nulonly; varflags = *p++; subtype = varflags & VSTYPE; @@ -733,12 +732,11 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; easy = (!quoted || (*var == '@' && shellparam.nparam)); - nulonly = easy; startloc = expdest - (char *)stackblock(); p = strchr(p, '=...
2020 Mar 28
0
[klibc:update-dash] dash: [EXPAND] Optimise nulonly away and just use quoted as before
...------ 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/usr/dash/expand.c b/usr/dash/expand.c index 9bbd19da..a2f99f14 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -722,7 +722,6 @@ evalvar(char *p, int flag) ssize_t varlen; int easy; int quoted; - int nulonly; varflags = *p++; subtype = varflags & VSTYPE; @@ -733,12 +732,11 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; easy = (!quoted || (*var == '@' && shellparam.nparam)); - nulonly = easy; startloc = expdest - (char *)stackblock(); p = strchr(p, '=...
2019 Jan 25
0
[klibc:update-dash] [EXPAND] Split unquoted $@/$* correctly when IFS is set but empty
...size_t varvalue(char *, int, int); +STATIC ssize_t varvalue(char *, int, int, int *); STATIC void expandmeta(struct strlist *, int); #ifdef HAVE_GLOB STATIC void addglob(const glob_t *); @@ -722,6 +722,7 @@ evalvar(char *p, int flag) ssize_t varlen; int easy; int quoted; + int nulonly; varflags = *p++; subtype = varflags & VSTYPE; @@ -732,11 +733,12 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; easy = (!quoted || (*var == '@' && shellparam.nparam)); + nulonly = easy; startloc = expdest - (char *)stackblock(); p = strchr(p, '=...
2020 Mar 28
0
[klibc:update-dash] dash: [EXPAND] Split unquoted $@/$* correctly when IFS is set but empty
...size_t varvalue(char *, int, int); +STATIC ssize_t varvalue(char *, int, int, int *); STATIC void expandmeta(struct strlist *, int); #ifdef HAVE_GLOB STATIC void addglob(const glob_t *); @@ -722,6 +722,7 @@ evalvar(char *p, int flag) ssize_t varlen; int easy; int quoted; + int nulonly; varflags = *p++; subtype = varflags & VSTYPE; @@ -732,11 +733,12 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; easy = (!quoted || (*var == '@' && shellparam.nparam)); + nulonly = easy; startloc = expdest - (char *)stackblock(); p = strchr(p, '=...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Do not reprocess data when expanding words
...har *)stackblock()) - startloc, (dest - (char *)stackblock()) - startloc, stackblock() + startloc)); + +out: + argbackq = argbackq->next; } @@ -626,33 +608,35 @@ scanright( return 0; } -STATIC const char * -subevalvar(char *p, char *str, int strloc, int subtype, int startloc, int varflags, int flag) +static char *subevalvar(char *start, char *str, int strloc, int startloc, + int varflags, int flag) { + int subtype = varflags & VSTYPE; int quotes = flag & QUOTES_ESC; char *startp; char *loc; - struct nodelist *saveargbackq = argbackq; - int amount; + long amount; c...
2019 Jan 25
0
[klibc:update-dash] expand: Fix ghost fields with unquoted $@/$*
...(char *, int, int, int *); +STATIC ssize_t varvalue(char *, int, int, int); STATIC void expandmeta(struct strlist *, int); #ifdef HAVE_GLOB STATIC void addglob(const glob_t *); @@ -712,7 +712,6 @@ evalvar(char *p, int flag) int c; int startloc; ssize_t varlen; - int easy; int quoted; varflags = *p++; @@ -723,12 +722,11 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; - easy = (!quoted || (*var == '@' && shellparam.nparam)); startloc = expdest - (char *)stackblock(); p = strchr(p, '=') + 1; again: - varlen = varvalue(var, varflag...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Fix ghost fields with unquoted $@/$*
...(char *, int, int, int *); +STATIC ssize_t varvalue(char *, int, int, int); STATIC void expandmeta(struct strlist *, int); #ifdef HAVE_GLOB STATIC void addglob(const glob_t *); @@ -712,7 +712,6 @@ evalvar(char *p, int flag) int c; int startloc; ssize_t varlen; - int easy; int quoted; varflags = *p++; @@ -723,12 +722,11 @@ evalvar(char *p, int flag) quoted = flag & EXP_QUOTED; var = p; - easy = (!quoted || (*var == '@' && shellparam.nparam)); startloc = expdest - (char *)stackblock(); p = strchr(p, '=') + 1; again: - varlen = varvalue(var, varflag...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Fix multiple issues with EXP_DISCARD in evalvar
...nged, 16 insertions(+), 14 deletions(-) diff --git a/usr/dash/expand.c b/usr/dash/expand.c index 411381bd..25236c09 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -698,6 +698,7 @@ evalvar(char *p, int flag) int patloc; int startloc; ssize_t varlen; + int discard; int quoted; varflags = *p++; @@ -713,41 +714,41 @@ again: if (varflags & VSNUL) varlen--; + discard = varlen < 0 ? EXP_DISCARD : 0; + switch (subtype) { case VSPLUS: - varlen = -1 - varlen; + discard ^= EXP_DISCARD; /* fall through */ case 0: case VSMINUS: - p = argstr(p, flag | EXP_TILDE...
2019 Jan 25
0
[klibc:update-dash] [EXPAND] Do not split quoted VSLENGTH and VSTRIM
....c @@ -753,28 +753,22 @@ vsplus: argstr(p, flag | EXP_TILDE | EXP_WORD); goto end; } - if (easy) - goto record; - goto end; + goto record; } if (subtype == VSASSIGN || subtype == VSQUESTION) { - if (varlen < 0) { - if (subevalvar(p, var, 0, subtype, startloc, - varflags, flag & ~QUOTES_ESC)) { - varflags &= ~VSNUL; - /* - * Remove any recorded regions beyond - * start of variable - */ - removerecordregions(startloc); - goto again; - } - goto end; - } - if (easy) + if (varlen >= 0) goto record; - goto end; + + subeval...
2020 Mar 28
0
[klibc:update-dash] dash: [EXPAND] Do not split quoted VSLENGTH and VSTRIM
....c @@ -753,28 +753,22 @@ vsplus: argstr(p, flag | EXP_TILDE | EXP_WORD); goto end; } - if (easy) - goto record; - goto end; + goto record; } if (subtype == VSASSIGN || subtype == VSQUESTION) { - if (varlen < 0) { - if (subevalvar(p, var, 0, subtype, startloc, - varflags, flag & ~QUOTES_ESC)) { - varflags &= ~VSNUL; - /* - * Remove any recorded regions beyond - * start of variable - */ - removerecordregions(startloc); - goto again; - } - goto end; - } - if (easy) + if (varlen >= 0) goto record; - goto end; + + subeval...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Merge syntax/quotes in memtodest with flags
...ize_t -strtodest(p, syntax, quotes) - const char *p; - const char *syntax; - int quotes; +static size_t strtodest(const char *p, int flags) { size_t len = strlen(p); - memtodest(p, len, syntax, quotes); + memtodest(p, len, flags); return len; } @@ -886,15 +879,14 @@ varvalue(char *name, int varflags, int flags, int quoted) int sep; char sepc; char **ap; - char const *syntax; int subtype = varflags & VSTYPE; int discard = subtype == VSPLUS || subtype == VSLENGTH; - int quotes = (discard ? 0 : (flags & QUOTES_ESC)) | QUOTES_KEEPNUL; ssize_t len = 0; char c; + flags |= EXP...
2019 Jan 25
0
[klibc:update-dash] expand: Fixed "$@" expansion when EXP_FULL is false
...s <ben at decadent.org.uk> --- usr/dash/expand.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/usr/dash/expand.c b/usr/dash/expand.c index a2f99f14..c04ff6e1 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -901,6 +901,7 @@ varvalue(char *name, int varflags, int flags, int *quotedp) int quotes = (discard ? 0 : (flags & QUOTES_ESC)) | QUOTES_KEEPNUL; ssize_t len = 0; + sep = (flags & EXP_FULL) << CHAR_BIT; syntax = quoted ? DQSYNTAX : BASESYNTAX; switch (*name) { @@ -931,16 +932,14 @@ numvar: expdest = p; break; case &...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Fixed "$@" expansion when EXP_FULL is false
...s <ben at decadent.org.uk> --- usr/dash/expand.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/usr/dash/expand.c b/usr/dash/expand.c index a2f99f14..c04ff6e1 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -901,6 +901,7 @@ varvalue(char *name, int varflags, int flags, int *quotedp) int quotes = (discard ? 0 : (flags & QUOTES_ESC)) | QUOTES_KEEPNUL; ssize_t len = 0; + sep = (flags & EXP_FULL) << CHAR_BIT; syntax = quoted ? DQSYNTAX : BASESYNTAX; switch (*name) { @@ -931,16 +932,14 @@ numvar: expdest = p; break; case &...
2020 Mar 28
0
[klibc:update-dash] dash: expand: Ensure result is escaped in cvtnum
...n)) - return; + return 0; q = makestrspace(len * 2, expdest); + s = q; do { int c = (signed char)*p++; @@ -818,6 +820,7 @@ static void memtodest(const char *p, size_t len, int flags) } while (--len); expdest = q; + return q - s; } @@ -875,7 +878,7 @@ varvalue(char *name, int varflags, int flags, int quoted) if (num == 0) return -1; numvar: - len = cvtnum(num); + len = cvtnum(num, flags); break; case '-': p = makestrspace(NOPTS, expdest); @@ -1711,15 +1714,13 @@ casematch(union node *pattern, char *val) * Our own itoa(). */ -STATIC int -cvtnum(int...
2020 Mar 28
0
[klibc:update-dash] dash: mkinit: Split reset into exitreset and reset
...-RESET { +EXITRESET { evalskip = 0; loopnest = 0; if (savestatus >= 0) { diff --git a/usr/dash/expand.c b/usr/dash/expand.c index 59a202cb..6ea0562f 100644 --- a/usr/dash/expand.c +++ b/usr/dash/expand.c @@ -1780,7 +1780,7 @@ varunset(const char *end, const char *var, const char *umsg, int varflags) INCLUDE "expand.h" -RESET { +EXITRESET { ifsfree(); } diff --git a/usr/dash/init.h b/usr/dash/init.h index e026e868..49791a07 100644 --- a/usr/dash/init.h +++ b/usr/dash/init.h @@ -35,5 +35,5 @@ */ void init(void); +void exitreset(void); void reset(void); -void initshellp...
2008 Apr 18
1
Wine release 0.9.60
This is release 0.9.60 of Wine, a free implementation of Windows on Unix. What's new in this release (see below for details): - Better support for Windows IMEs. - Option for Windows-style window decorations. - Improved system tray behavior. - Window management fixes. - Improved quartz audio support. - Better support for launching apps from Unix file managers. - Lots of bug