Ben 🇪🇺 is a user on octodon.social. You can follow them or interact with them if you have an account anywhere in the fediverse. If you don't, you can sign up here.

i'll probably regret asking but what's wrong with strcpy and what should you use instead then

Ben 🇪🇺 @benofbrown

@squirrel strcpy doesn't check that the destination is big enough to store the source string in, which can lead to buffer overruns.

The Linux man page for strcpy covers this fairly well, along with some alternatives: linux.die.net/man/3/strcpy

· Web · 0 · 0