From: Richard M. Stallman Date: Mon, 11 Aug 1997 21:44:08 +0000 (+0000) Subject: (init_environment): Set Emacs root directory properly when X-Git-Tag: emacs-20.1~653 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=5d7e8345557656c240b0305366d51f1b8e4bcc40;p=emacs.git (init_environment): Set Emacs root directory properly when the executable is in its `src' subdirectory, as under a debugger. (IT_set_face): If termscript is in use, print the number of the face as well. --- diff --git a/src/msdos.c b/src/msdos.c index bed172fa03e..a35e1bce552 100644 --- a/src/msdos.c +++ b/src/msdos.c @@ -591,7 +591,8 @@ IT_set_face (int face) else fp = intern_face (selected_frame, FRAME_COMPUTED_FACES (foo)[face]); if (termscript) - fprintf (termscript, "", FACE_FOREGROUND (fp), FACE_BACKGROUND (fp)); + fprintf (termscript, "", + face, FACE_FOREGROUND (fp), FACE_BACKGROUND (fp)); screen_face = face; ScreenAttrib = (FACE_BACKGROUND (fp) << 4) | FACE_FOREGROUND (fp); } @@ -2708,10 +2709,12 @@ init_environment (argc, argv, skip_args) while (len > 0 && root[len] != '/' && root[len] != ':') len--; root[len] = '\0'; - if (len > 4 && strcmp (root + len - 4, "/bin") == 0) + if (len > 4 + && (strcmp (root + len - 4, "/bin") == 0 + || strcmp (root + len - 4, "/src") == 0)) /* under a debugger */ root[len - 4] = '\0'; else - strcpy (root, "c:/emacs"); /* Only under debuggers, I think. */ + strcpy (root, "c:/emacs"); /* let's be defensive */ len = strlen (root); strcpy (emacsroot, root);