From: Chris W. <ch...@qw...> - 2010-06-21 07:50:57
|
Hi Stefano, On Mon, 21 Jun 2010, Stefano Sabatini wrote: > On date Friday 2010-06-18 19:21:55 +0300, Tor Lillqvist wrote: >> You assuming a relatively obscure function like swprintf() is the same >> in two unrelated C libraries just because it has the same name? > > I assume a standardized function like swprintf() to be the same in two > different C libraries. [...] > http://www.globalyzer.com/gi/help/gihelp/unsafeMethod/snprintf.htm >From that very same page: "The swprintf function is unusual in that the ANSI version and the Windows version of swprintf are actually different functions. This help page documents the ANSI swprintf function... The Windows swprintf function on the hand is a wide version of sprintf. If scanning a Windows code base and investigating the swprintf function, this is the wrong help page. Please see Windows swprintf instead." And following that link: "The swprintf function is unusual in that the ANSI version and the Windows version of swprintf are actually different functions. This help page documents the Windows swprintf function, which is a wide version of sprintf." > In other words, I can't see why MinGW is not following ISO C. Because Microsoft's runtime doesn't, and that's what MinGW uses. Cheers, Chris. -- _ ___ __ _ / __/ / ,__(_)_ | Chris Wilson <0000 at qwirx.com> - Cambs UK | / (_/ ,\/ _/ /_ \ | Security/C/C++/Java/Perl/SQL/HTML Developer | \ _/_/_/_//_/___/ | We are GNU-free your mind-and your software | |