The following code gives the right result when compiled without defined __USE_MINGW_ANSI_STDIO macro. But, if __USE_MINGW_ANSI_STDIO macro is defined - the result is 6. Why?
code: #include <stdio.h> int main() { wchar_t buf[2]; int len = snwprintf(buf, sizeof(buf) / 2, L"world!"); printf("%d\n", len); } Thanks. -- Regards, niXman ___________________________________________________ Dual-target(32 & 64 bit) MinGW compilers for 32 and 64 bit Windows: http://sourceforge.net/projects/mingwbuilds/ ------------------------------------------------------------------------------ Live Security Virtual Conference Exclusive live event will cover all the ways today's security and threat landscape has changed and how IT managers can respond. Discussions will include endpoint security, mobile security and the latest in malware threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/ _______________________________________________ Mingw-w64-public mailing list Mingw-w64-public@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/mingw-w64-public