compatibility: stick “set ±o arc4random” around for a bit longer,

until R40 is definitively out (so there MAY still be an R39d)

this commit can easily be reverted in its entirety later, when
Build.sh’s compatibility for “-combine” &c. is removed too
This commit is contained in:
tg
2010-07-13 13:07:58 +00:00
parent 0a5d6bc71b
commit ad98b9fc4a
3 changed files with 18 additions and 4 deletions

8
misc.c
View File

@ -29,7 +29,7 @@
#include <grp.h>
#endif
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.139 2010/07/04 17:33:55 tg Exp $");
__RCSID("$MirOS: src/bin/mksh/misc.c,v 1.140 2010/07/13 13:07:56 tg Exp $");
unsigned char chtypes[UCHAR_MAX + 1]; /* type bits for unsigned char */
@ -329,6 +329,12 @@ parse_args(const char **argv,
break;
}
i = option(go.optarg);
if ((enum sh_flag)i == FARC4RANDOM) {
warningf(true, "Do not use set ±o arc4random,"
" it will be removed in the next version"
" of mksh!");
return (0);
}
if ((i != (size_t)-1) && set == Flag(i))
/* Don't check the context if the flag
* isn't changing - makes "set -o interactive"