+
+void
+reset_shell_flags ()
+{
+ mark_modified_vars = exit_immediately_on_error = disallow_filename_globbing = 0;
+ place_keywords_in_env = read_but_dont_execute = just_one_command = 0;
+ noclobber = unbound_vars_is_error = echo_input_at_read = 0;
+ echo_command_at_execute = jobs_m_flag = forced_interactive = 0;
+ no_symbolic_links = no_invisible_vars = privileged_mode = pipefail_opt = 0;
+
+ hashing_enabled = interactive_comments = 1;
+
+#if defined (JOB_CONTROL)
+ asynchronous_notification = 0;
+#endif
+
+#if defined (BANG_HISTORY)
+ history_expansion = 1;
+#endif
+
+#if defined (BRACE_EXPANSION)
+ brace_expansion = 1;
+#endif
+
+#if defined (RESTRICTED_SHELL)
+ restricted = 0;
+#endif
+}
+
+void
+initialize_flags ()
+{
+ register int i;
+
+ for (i = 0; shell_flags[i].name; i++)
+ optflags[i+1] = shell_flags[i].name;
+ optflags[++i] = 'o';
+ optflags[++i] = ';';
+ optflags[i+1] = '\0';
+}