diff options
author | jilles <jilles@FreeBSD.org> | 2015-08-29 19:41:47 +0000 |
---|---|---|
committer | jilles <jilles@FreeBSD.org> | 2015-08-29 19:41:47 +0000 |
commit | 699c9af55ff3a18628f73db3446e39b34584b5c3 (patch) | |
tree | 45b72c61b2eb6f3af29b6ecc93085301321208f2 /bin/sh/options.h | |
parent | ef54b2af3d94323df123e6375fe24accb5b54e3c (diff) | |
download | FreeBSD-src-699c9af55ff3a18628f73db3446e39b34584b5c3.zip FreeBSD-src-699c9af55ff3a18628f73db3446e39b34584b5c3.tar.gz |
sh: Add set -o nolog.
POSIX requires this to prevent entering function definitions in history but
this implementation does nothing except retain the option's value. In ksh88,
function definitions were usually entered in the history file, even when
they came from ~/.profile and the $ENV file, to allow displaying their
definitions.
This is also the first option that does not have a letter.
Diffstat (limited to 'bin/sh/options.h')
-rw-r--r-- | bin/sh/options.h | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/bin/sh/options.h b/bin/sh/options.h index 2048a35..b5cd67f 100644 --- a/bin/sh/options.h +++ b/bin/sh/options.h @@ -64,8 +64,10 @@ struct shparam { #define Tflag optlist[16].val #define Pflag optlist[17].val #define hflag optlist[18].val +#define nologflag optlist[19].val -#define NOPTS 19 +#define NSHORTOPTS 19 +#define NOPTS 20 struct optent { const char *name; @@ -95,6 +97,7 @@ struct optent optlist[NOPTS] = { { "trapsasync", 'T', 0 }, { "physical", 'P', 0 }, { "trackall", 'h', 0 }, + { "nolog", '\0', 0 }, }; #endif |