shell: typo and whitespace fixes, no code changes

Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
This commit is contained in:
Denys Vlasenko 2025-08-03 23:29:35 +02:00
parent 02b518db1c
commit d7d8ffed87
2 changed files with 2 additions and 16 deletions

View file

@ -329,7 +329,7 @@ typedef long arith_t;
/* ============ Shell options */
/* If you add/change options hare, update --help text too */
/* If you add/change options here, update --help text too */
static const char *const optletters_optnames[] ALIGN_PTR = {
"e" "errexit",
"f" "noglob",
@ -1596,7 +1596,6 @@ struct stackmark {
size_t stacknleft;
};
struct globals_memstack {
struct stack_block *g_stackp; // = &stackbase;
char *g_stacknxt; // = stackbase.space;
@ -1619,7 +1618,6 @@ extern struct globals_memstack *BB_GLOBAL_CONST ash_ptr_to_globals_memstack;
sstrend = stackbase.space + MINSIZE; \
} while (0)
#define stackblock() ((void *)g_stacknxt)
#define stackblocksize() g_stacknleft
@ -2121,7 +2119,6 @@ struct localvar {
# define VDYNAMIC 0
#endif
/* Need to be before varinit_data[] */
#if ENABLE_LOCALE_SUPPORT
static void FAST_FUNC
@ -3007,7 +3004,6 @@ pwdcmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
/* ============ ... */
#define IBUFSIZ (ENABLE_FEATURE_EDITING ? CONFIG_FEATURE_EDITING_MAX_LEN : 1024)
/* Syntax classes */
@ -3414,13 +3410,11 @@ struct alias {
int flag;
};
static struct alias **atab; // [ATABSIZE];
#define INIT_G_alias() do { \
atab = xzalloc(ATABSIZE * sizeof(atab[0])); \
} while (0)
static struct alias **
__lookupalias(const char *name)
{
@ -3602,7 +3596,6 @@ unaliascmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
#endif /* ASH_ALIAS */
/* Mode argument to forkshell. Don't change FORK_FG or FORK_BG. */
#define FORK_FG 0
#define FORK_BG 1
@ -5462,7 +5455,6 @@ stoppedjobs(void)
return retval;
}
/*
* Code for dealing with input/output redirection.
*/
@ -8935,7 +8927,6 @@ commandcmd(int argc UNUSED_PARAM, char **argv UNUSED_PARAM)
}
#endif
/*static int funcblocksize; // size of structures in function */
/*static int funcstringsize; // size of strings in node */
static void *funcblock; /* block to allocate function from */
@ -10698,7 +10689,6 @@ goodname(const char *p)
return endofname(p)[0] == '\0';
}
/*
* Search for a command. This is called before we fork so that the
* location of the command will be available in the parent as well as
@ -13448,7 +13438,6 @@ parseheredoc(void)
}
}
static const char *
expandstr(const char *ps, int syntax_type)
{
@ -14037,7 +14026,6 @@ find_command(char *name, struct cmdentry *entry, int act, const char *path)
entry->u = cmdp->param;
}
/*
* The trap builtin.
*/
@ -14631,7 +14619,6 @@ init(void)
}
}
//usage:#define ash_trivial_usage
//usage: "[-il] [-|+Cabefmnuvx] [-|+o OPT]... [-c 'SCRIPT' [ARG0 ARGS] | FILE ARGS | -s ARGS]"
//////// comes from ^^^^^^^^^^optletters
@ -14911,7 +14898,6 @@ int ash_main(int argc UNUSED_PARAM, char **argv)
/* NOTREACHED */
}
/*-
* Copyright (c) 1989, 1991, 1993, 1994
* The Regents of the University of California. All rights reserved.

View file

@ -10877,7 +10877,7 @@ int hush_main(int argc, char **argv)
/* Often both pgrps here are set to our pid - but not always!
* Example: sh -c 'echo $$; hush; echo FIN'
* Here, the parent shell is not interactive, so it does NOT set up
* a separate process group for its children, and we (hush) initinally
* a separate process group for its children, and we (hush) initially
* run in parent's process group (until we set up our own a few lines down).
*/
//bb_error_msg("process groups tty:%d hush:%d", G_saved_tty_pgrp, shell_pgrp);