This is the mail archive of the gdb-patches@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Fix compilation using mingw.org's MinGW


> Date: Thu, 18 Apr 2019 10:00:58 -0700
> From: Kevin Buettner <kevinb@redhat.com>
> Cc: gdb-patches@sourceware.org
> 
> > +#if _WIN32_WINNT < 0x0501
> > +
> > +typedef
> > +struct _CONSOLE_FONT_INFO
> > +{ DWORD 			nFont;
> > +  COORD 			dwFontSize;
> > +} CONSOLE_FONT_INFO, *PCONSOLE_FONT_INFO;
> > +
> > +#endif
> > +
> >  typedef BOOL WINAPI (AdjustTokenPrivileges_ftype) (HANDLE, BOOL,
> >  						   PTOKEN_PRIVILEGES,
> >  						   DWORD, PTOKEN_PRIVILEGES,
> 
> I had expected to see a typedef for struct CONSOLE_FONT_INFO, but
> instead see one for _CONSOLE_FONT_INFO (where the difference is
> the leading underscore.)

The struct is with the leading underscore, the typedef isn't.

> I'm guessing that there's some magic in Windows specific header files
> which makes this work, but I just want to check to make sure that this
> wasn't a typo on your part...

It wasn't a typo, and there is no magic ;-)


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]