Re: [Mingw-w64-public] swscanf() crashes if __USE_MINGW_ANSI_STDIO is defined

2017-11-14 Thread David Lee
On 14 November 2017 at 11:40, Liu Hao wrote: > On 2017/11/14 9:58, Liu Hao wrote: >> On 2017/11/13 11:11, David Lee wrote: >>> Built and tested a cross compiler (i686-w64-mingw32-gcc 6.4.0) on >>> debian stretch with master mingw-w64. Same crash. >>> >

Re: [Mingw-w64-public] swscanf() crashes if __USE_MINGW_ANSI_STDIO is defined

2017-11-12 Thread David Lee
On 12 November 2017 at 15:28, David Lee wrote: > On 11 November 2017 at 21:47, Hannes Domani via Mingw-w64-public > wrote: >> Am Samstag, 11. November 2017, 10:15:00 MEZ hat Liu Hao >> Folgendes geschrieben: >> >>> Debugging in assembly exposes indirection thr

Re: [Mingw-w64-public] swscanf() crashes if __USE_MINGW_ANSI_STDIO is defined

2017-11-11 Thread David Lee
e is even the suggestion that mingw_wvfscanf.c might need a similar fix, > which was never done. > Looks like the fix was in mingw_vfscanf.c but not in mingw_wvfscanf.c. optimize_alloc() looks different in each file. I'll try building a GCC with master mingw-w64, test it and see what hap

[Mingw-w64-public] swscanf() crashes if __USE_MINGW_ANSI_STDIO is defined

2017-11-10 Thread David Lee
he program crashed. The swscanf() call still crashed with different specifiers: "%s", and "%S" The compiler used were downloaded from here (5.4.0 and 6.4.0) https://sourceforge.net/projects/mingw-w64/files/Multilib%20Toolchains%

Re: [Mingw-w64-public] Calling wprintf from a C++ program

2017-11-09 Thread David Lee
++ 5.4.0 this is just a C header. On g++ 6.4.0 this is actually a header in a C++ directory, which in turn includes . So __USE_MINGW_ANSI_STDIO is defined. Regards, David Lee On 9 November 2017 at 16:02, Liu Hao wrote: > On 2017/11/9 15:46, David Lee wrote: >> >> Thanks for the repl

Re: [Mingw-w64-public] Calling wprintf from a C++ program

2017-11-08 Thread David Lee
changed to cstdio and/or cwchar (so *wprintf() are no longer broken), Then the format specifiers are something to watch for. Regards, David Lee On 9 November 2017 at 13:39, Liu Hao wrote: > On 2017/11/9 12:13, David Lee wrote: >> >> Hello. I have an issue that isn't necessar

[Mingw-w64-public] Calling wprintf from a C++ program

2017-11-08 Thread David Lee
Hello. I have an issue that isn't necessarily related to mingw-w64. Could be gcc/g++, libstdc++ or even my mistake. Let me have a starting point here. I downloaded Mingw-w64 GCC toolchains (5.4.0, 6.4.0, sjlj, x86 version) from here: https://sourceforge.net/projects/mingw-w64/files/Multilib%20Too