Skip to content
Snippets Groups Projects
Commit a8c0ac5d authored by Rob Swindell's avatar Rob Swindell :speech_balloon:
Browse files

Fix stale comment about XSAFECOPY (now uses strlcpy, not strncpy)

parent d13fa3bd
No related branches found
No related tags found
1 merge request!455Update branch with changes from master
Pipeline #6247 canceled
......@@ -439,7 +439,7 @@ typedef struct {
#define SAFECOPY(dst,src) strlcpy(dst,src,sizeof(dst))
#endif
/* Extra-safe SAFECOPY doesn't pass NULL-pointer to strncpy */
/* Extra-safe SAFECOPY doesn't pass NULL-pointer to strlcpy */
#ifdef _DEBUG
#define XSAFECOPY(dst,src) do { \
static_assert(sizeof(dst) != sizeof(void*), "SAFECOPY() on pointer-sized dst, use strlcpy"); \
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment