+ 4
unable to use safe string function in C
C11 introduces new function to eradicate buffer overflow while using string in C, --> strnlen_s, strncmpy_s etc where introduced, according to my research I can use this function using #define __STDC_WANT_LIB_EXT1__ 1, the problem now is that it's not working https://code.sololearn.com/cvNapT5f0CFV/?ref=app
13 odpowiedzi
+ 3
You can see a reason for the problem here : https://stackoverflow.com/questions/47867130/stdc-lib-ext1-availability-in-gcc-and-clang
+ 5
~ swim ~ its not working on a compiler
+ 4
~ swim ~ according to the information TheWhiteCat💡 provided for me, it was not full accepted into the gnu11
+ 4
version 4.2.1 on my mobile
4.9.2 on my PC
+ 4
thanks ~ swim ~ 👍👍👍
+ 3
You can find useful info in this discussion: https://stackoverflow.com/questions/15610053/correct-printf-format-specifier-for-size-t-zu-or-iu?lq=1. According to the discussion this prefix "z" is not supported by Microsoft. You can use "I". You can see it in the code.
https://code.sololearn.com/cvEyE4Wac4m1/?ref=app
+ 3
TheWhiteCat💡 thanks I will check the link out now, but the last printf is not outputting anything, which is the part I really need
edited: thanks, the thread do not answer my question
+ 2
thanks alot TheWhiteCat💡 , now I need to get my hope out of that, maybe create my own safe functions, 😉😉😉😉
+ 1
*AsterisK* , you are welcome 😉