changeset 81605:69c77f0f3507

(main): Set console codepages to "ANSI".
author Jason Rumney <jasonr@gnu.org>
date Mon, 25 Jun 2007 12:35:05 +0000
parents feafa882a0cf
children 19ee9b6ece0e
files nt/cmdproxy.c
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/nt/cmdproxy.c	Mon Jun 25 05:09:05 2007 +0000
+++ b/nt/cmdproxy.c	Mon Jun 25 12:35:05 2007 +0000
@@ -466,6 +466,12 @@
   SetCurrentDirectory (modname);
   *progname = '\\';
 
+  /* Due to problems with interaction between API functions that use "OEM"
+     codepage vs API functions that use the "ANSI" codepage, we need to
+     make things consistent by choosing one and sticking with it.  */
+  SetConsoleCP (GetACP());
+  SetConsoleOutputCP (GetACP());
+
   /* Although Emacs always sets argv[0] to an absolute pathname, we
      might get run in other ways as well, so convert argv[0] to an
      absolute name before comparing to the module name.  Don't get