From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from list by lists.gnu.org with archive (Exim 4.71) id 1VwbQh-0001nm-Vp for mharc-grub-devel@gnu.org; Fri, 27 Dec 2013 12:42:35 -0500 Received: from eggs.gnu.org ([2001:4830:134:3::10]:47710) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VwbQY-0001lQ-2a for grub-devel@gnu.org; Fri, 27 Dec 2013 12:42:34 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VwbQP-0000VC-Ku for grub-devel@gnu.org; Fri, 27 Dec 2013 12:42:26 -0500 Received: from mail-la0-x22e.google.com ([2a00:1450:4010:c03::22e]:39361) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VwbQP-0000V3-DK for grub-devel@gnu.org; Fri, 27 Dec 2013 12:42:17 -0500 Received: by mail-la0-f46.google.com with SMTP id eh20so4341548lab.5 for ; Fri, 27 Dec 2013 09:42:16 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=from:to:subject:date:message-id; bh=SSSx1PR3A7mXirRX6sNg2gPx2N8BGiaouPhgINT+ino=; b=U2TEYo6cbWdc+oz68utJ01UTKKeZLXFuuoMwaxGS5jUm5Apwtoc/jHlHg/3jT9Cibl wvcJEUPUmdbe5Qapb/NQt+Dv2ktOWGNL+JZnFMIaF7DoMGCxQNf2a9y4lBDszigX2cdA EGpyBLEeR36OGnMOmnlywWEC4En86XLgQbK42ls0TGRtO6GvxtwexB4/QOlLQTMQ65l6 CGdcdDbBwrFSclXtK+el1OtjrG9wKj3cOanS3qWcHs2EprMG68+wMs5DPNzqEuKmN5Te 803zDkCP3EIZl7IIyeS1/ydMKJg9IFA2WLePQ++RFTeiUUOMbfuz+3S4LOIMrDcOcXln 8OoQ== X-Received: by 10.152.180.228 with SMTP id dr4mr6456191lac.32.1388166136298; Fri, 27 Dec 2013 09:42:16 -0800 (PST) Received: from localhost.localdomain (ppp91-76-134-134.pppoe.mtu-net.ru. [91.76.134.134]) by mx.google.com with ESMTPSA id bl6sm21519668lbb.5.2013.12.27.09.42.15 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 27 Dec 2013 09:42:15 -0800 (PST) From: Andrey Borzenkov To: grub-devel@gnu.org Subject: [PATCH] do not reset console font when running utils on Windows Date: Fri, 27 Dec 2013 21:42:12 +0400 Message-Id: <1388166132-10890-1-git-send-email-arvidjaar@gmail.com> X-Mailer: git-send-email 1.8.4 X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c03::22e X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list Reply-To: The development of GNU GRUB List-Id: The development of GNU GRUB List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 27 Dec 2013 17:42:34 -0000 This is not required as utilities provide just simple text output. This avoids surprising unexpected change of window look'n'feel. --- grub-core/osdep/windows/init.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/grub-core/osdep/windows/init.c b/grub-core/osdep/windows/init.c index 98c325c..629d785 100644 --- a/grub-core/osdep/windows/init.c +++ b/grub-core/osdep/windows/init.c @@ -30,6 +30,7 @@ #include "progname.h" +#ifndef GRUB_UTIL struct grub_windows_console_font_infoex { ULONG cbSize; DWORD nFont; @@ -111,6 +112,7 @@ set_console_unicode_font (void) func_SetConsoleFont (err_handle, 12); } } +#endif static char *grub_util_base_directory; static char *locale_dir; @@ -148,10 +150,12 @@ grub_util_host_init (int *argc __attribute__ ((unused)), { char *ptr; +#infdef GRUB_UTIL SetConsoleOutputCP (CP_UTF8); SetConsoleCP (CP_UTF8); set_console_unicode_font (); +#endif #if SIZEOF_TCHAR == 1 -- tg: (645ff63..) u/mingw/console-font (depends on: master)