subshells should not inherit FIFOs; initial framework for nofork (foreground) command substitutions

This commit is contained in:
Chet Ramey
2023-05-09 10:33:56 -04:00
parent 896df2874a
commit c375f8f45f
11 changed files with 341 additions and 34 deletions
+5
View File
@@ -52,6 +52,7 @@
#define PST_NOERROR 0x800000 /* don't print error messages in yyerror */
#define PST_STRING 0x1000000 /* parsing a string to a command or word list */
#define PST_CMDBLTIN 0x2000000 /* last token was the `command' builtin */
#define PST_FUNSUBST 0x4000000 /* parsing a foreground command substitution */
/* Definition of the delimiter stack. Needed by parse.y and bashhist.c. */
struct dstack {
@@ -75,6 +76,10 @@ struct dstack {
#define DOLBRACE_QUOTE 0x40 /* single quote is special in double quotes */
#define DOLBRACE_QUOTE2 0x80 /* single quote is semi-special in double quotes */
/* characters that can appear following ${ to introduce a function or value
substitution (this is mksh terminology and needs to be changed). */
#define FUNSUB_CHAR(n) ((n) == ' ' || (n) == '\t' || (n) == '\n' || (n) == '|')
/* variable declarations from parse.y */
extern struct dstack dstack;