1
0
mirror of https://git.savannah.gnu.org/git/emacs.git synced 2025-01-19 18:13:55 +00:00

[WINDOWSNT]: Force the first argv passed to execvp to point to alternate_editor

(otherwise .BAT scripts can't run).
This commit is contained in:
Juanma Barranquero 2006-11-01 19:26:14 +00:00
parent 8ea882655e
commit b73ea44bb7

View File

@ -250,6 +250,9 @@ fail (argc, argv)
if (alternate_editor)
{
int i = optind - 1;
#ifdef WINDOWSNT
argv[i] = (char *)alternate_editor;
#endif
execvp (alternate_editor, argv + i);
fprintf (stderr, "%s: error executing alternate editor \"%s\"\n",
progname, alternate_editor);