From: Andrew Innes Date: Mon, 28 Dec 1998 19:28:19 +0000 (+0000) Subject: (_start): Force system calls accessing unmounted devices to fail X-Git-Tag: emacs-20.4~1001 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=467af476c1ba9c36f6a621fde0e7cfd531b95ec3;p=emacs.git (_start): Force system calls accessing unmounted devices to fail without prompting. --- diff --git a/src/unexw32.c b/src/unexw32.c index 2363e7e73d0..f7314e79207 100644 --- a/src/unexw32.c +++ b/src/unexw32.c @@ -155,6 +155,10 @@ _start (void) having us exit. */ SetConsoleCtrlHandler ((PHANDLER_ROUTINE) ctrl_c_handler, TRUE); + /* Prevent Emacs from being locked up (eg. in batch mode) when + accessing devices that aren't mounted (eg. removable media drives). */ + SetErrorMode (SEM_FAILCRITICALERRORS); + /* Invoke the NT CRT startup routine now that our housecleaning is finished. */ #ifdef HAVE_NTGUI