This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
Re: [RFA] defs.h: Define GDB_DEFAULT_TARGET_[WIDE_]CHARSET for Cygwin and MingW builds
- From: Eli Zaretskii <eliz at gnu dot org>
- To: gdb-patches at sourceware dot org
- Date: Mon, 01 Mar 2010 19:11:15 +0200
- Subject: Re: [RFA] defs.h: Define GDB_DEFAULT_TARGET_[WIDE_]CHARSET for Cygwin and MingW builds
- References: <20100228130500.GG5683@calimero.vinschen.de> <20100228142905.GB1556@caradoc.them.org> <20100228150318.GA32463@calimero.vinschen.de> <20100228184749.GA17375@caradoc.them.org> <20100228192159.GP5683@calimero.vinschen.de> <20100228222702.GC29360@caradoc.them.org> <20100301103125.GB9730@calimero.vinschen.de>
- Reply-to: Eli Zaretskii <eliz at gnu dot org>
> Date: Mon, 1 Mar 2010 11:31:25 +0100
> From: Corinna Vinschen <vinschen@redhat.com>
>
> @@ -2296,12 +2297,20 @@ void
> _initialize_windows_nat (void)
> {
> struct cmd_list_element *c;
> +#ifndef __CYGWIN__
> + static char codepage[32];
> +#endif
>
> init_windows_ops ();
>
> #ifdef __CYGWIN__
> cygwin_internal (CW_SET_DOS_FILE_WARNING, 0);
> + set_auto_target_charset ("UTF-8");
> +#else
> + snprintf (codepage, 32, "CP%u", GetACP ());
^^
Could this be `sizeof(codepage)' instead, please?
Thanks.