struct mapping_defn_t *mappings;
};
-static unsigned option_mask;
#define OPTION_STR "anvf" USE_FEATURE_IFUPDOWN_MAPPING("m") "i:"
enum {
OPT_do_all = 0x1,
OPT_force = 0x8,
OPT_no_mappings = 0x10,
};
-#define DO_ALL (option_mask & OPT_do_all)
-#define NO_ACT (option_mask & OPT_no_act)
-#define VERBOSE (option_mask & OPT_verbose)
-#define FORCE (option_mask & OPT_force)
-#define NO_MAPPINGS (option_mask & OPT_no_mappings)
+#define DO_ALL (option_mask32 & OPT_do_all)
+#define NO_ACT (option_mask32 & OPT_no_act)
+#define VERBOSE (option_mask32 & OPT_verbose)
+#define FORCE (option_mask32 & OPT_force)
+#define NO_MAPPINGS (option_mask32 & OPT_no_mappings)
static char **__myenviron;
static int doit(char *str)
{
- if (option_mask & (OPT_no_act|OPT_verbose)) {
+ if (option_mask32 & (OPT_no_act|OPT_verbose)) {
puts(str);
}
- if (!(option_mask & OPT_no_act)) {
+ if (!(option_mask32 & OPT_no_act)) {
pid_t child;
int status;
int any_failures = 0;
int i;
- if (bb_applet_name[2] == 'u') {
+ if (applet_name[2] == 'u') {
/* ifup command */
cmds = iface_up;
} else {
cmds = iface_down;
}
- option_mask = getopt32(argc, argv, OPTION_STR, &interfaces);
+ getopt32(argc, argv, OPTION_STR, &interfaces);
if (argc - optind > 0) {
if (DO_ALL) bb_show_usage();
} else