+#if 0 /* defined (WIN32_NATIVE) */
+ /* BAD BAD BAD. We do not wanting to be passing an XEmacs-created
+ SHELL var down to some inferior Cygwin process, which might get
+ screwed up.
+
+ There are a few broken apps (eterm/term.el, eterm/tshell.el,
+ os-utils/terminal.el, texinfo/tex-mode.el) where this will
+ cause problems. Those broken apps don't look at
+ shell-file-name, instead just at explicit-shell-file-name,
+ ESHELL and SHELL. They are apparently attempting to borrow
+ what `M-x shell' uses, but that latter also looks at
+ shell-file-name. What we want is for all of these apps to look
+ at shell-file-name, so that the user can change the value of
+ shell-file-name and everything will work out hunky-dorey.
+ */
+
+ if (!egetenv ("SHELL"))
+ {
+ CBufbyte *faux_var = alloca_array (CBufbyte, 7 + strlen (shell));
+ sprintf (faux_var, "SHELL=%s", shell);
+ Vprocess_environment = Fcons (build_string (faux_var),
+ Vprocess_environment);
+ }
+#endif /* 0 */
+