Displaying 4 results from an estimated 4 matches for "local_snprintf".
2014 Sep 21
2
[PATCH] flac version of (v)snprintf
The patch changes flac_snprintf (in src/share/grabbag/snprintf.c)
and its copy local_snprintf (src/libFLAC/metadata_iterators.c).
It also adds flac_vsnprintf (src/share/grabbag/snprintf.c) and
its copy local_vsnprintf (src/share/win_utf8_io/win_utf8_io.c).
And it changes stats_print_info in src/flac/utils.c so it uses flac_vsnprintf
instead of vsnprintf. Return value checking becomes unne...
2014 Sep 12
2
win_utf8_io.c: Use fputws instead of fwprintf
Hi
On MSVCRT, wprintf expects that %s is wide char string, but for not MSVCRT, this is not true.
When using -D__USE_MINGW_ANSI_STDIO=1 on MINGW, mingw doesn't use MSVCRT.
Therefore, compiling on mingw with -D__USE_MINGW_ANSI_STDIO=1 and redirecting stderr to a file, the printing result is corrupt.
We should use fputws simply.
A patch is attached.
-------------- next part
2014 Sep 20
0
vsnprintf_s and vsnprintf
...#39;ll write
> a unit test for flac_snprintf to capture our assumptions.
I would like to know opinions of other people... Especially because I'm not
very familiar with MinGW. Anyone?
P.S. There are 3 places where flac uses vsnprintf:
1) flac_snprintf inside src/share/grabbag/snprintf.c
2) local_snprintf inside src/libFLAC/metadata_iterators.c -- but it's a full copy of flac_snprintf
3) printf_utf8/fprintf_utf8/vfprintf_utf8 inside src/share/win_utf8_io/win_utf8_io.c
2014 Sep 20
3
vsnprintf_s and vsnprintf
lvqcl wrote:
> Why? We can use vsnprintf_s for MSVS, and vsnprintf for MinGW.
>
> MSVS version of vsnprintf_s is located inside (statically linked) msvcp???.lib
> or (dynamically linked) msvcp???.dll. They are part of MSVS runtime, and compatible
> with WinXP. So it is safe to use it in FLAC.
Oh, ok. I missed this bit. I know so very little about Windows.
However, if you compile