Re:Everything I wish I knew when learning C
by AstralStorm on Monday November 28, 2022 @09:23AM
(#33773930)
Then there are strn*_s since C11 (and available before that on many platforms) which do exactly what you want.
[ Parent
| on HN ]
Re:Everything I wish I knew when learning C
by masklinn on Monday November 28, 2022 @09:40AM
(#33774128)
Lol no. These are the Annex K stuff which Microsoft got into the standard, which got standardised with a different behaviour than Windows’ (so even on windows following the spec doesn’t work) and which no one else wants to implement at all.
And they don’t actually “do exactly what you want”, see for instance N1967 (“field experience with annex k”) which is less than glowing.