Re: [Mingw-w64-public] [PATCH] crt: Add missing snprintf aliases

2016-04-29 Thread Hugo Beauzée-Luyssen
On 04/29/2016 11:54 AM, Ozkan Sezer wrote: > On 4/29/16, lh_mouse wrote: >> snprintf() and _snprintf() are not equivalent. >> >> Given the following program: >> ``` >> #include >> >> int main(){ >> char str[] = "0123456789"; >> _snprintf(str, 5, "%s", "-"); >> puts(str); >> } >

Re: [Mingw-w64-public] [PATCH] crt: Add missing snprintf aliases

2016-04-29 Thread Ozkan Sezer
On 4/29/16, lh_mouse wrote: > snprintf() and _snprintf() are not equivalent. > > Given the following program: > ``` > #include > > int main(){ > char str[] = "0123456789"; > _snprintf(str, 5, "%s", "-"); > puts(str); > } > ``` > A standard-conforming program should write a n

Re: [Mingw-w64-public] [PATCH] crt: Add missing snprintf aliases

2016-04-29 Thread lh_mouse
snprintf() and _snprintf() are not equivalent. Given the following program: ``` #include int main(){ char str[] = "0123456789"; _snprintf(str, 5, "%s", "-"); puts(str); } ``` A standard-conforming program should write a null terminator at str[4], truncating the outpu

[Mingw-w64-public] [PATCH] crt: Add missing snprintf aliases

2016-04-29 Thread Hugo Beauzée-Luyssen
--- mingw-w64-crt/lib32/msvcr120_app.def.in | 1 + mingw-w64-crt/lib64/msvcr120_app.def.in | 1 + 2 files changed, 2 insertions(+) diff --git a/mingw-w64-crt/lib32/msvcr120_app.def.in b/mingw-w64-crt/lib32/msvcr120_app.def.in index 579edb3..bb1f214 100644 --- a/mingw-w64-crt/lib32/msvcr120_app.d