Ban strncpy() it's too easy to misuse.
authorAlex Converse <aconverse@google.com>
Tue, 3 May 2011 18:21:49 +0000 (11:21 -0700)
committerAlex Converse <alex.converse@gmail.com>
Sun, 8 May 2011 19:49:07 +0000 (12:49 -0700)
libavutil/internal.h

index 37bc681..e890ae7 100644 (file)
 #define sprintf sprintf_is_forbidden_due_to_security_issues_use_snprintf
 #undef  strcat
 #define strcat strcat_is_forbidden_due_to_security_issues_use_av_strlcat
+#undef  strncpy
+#define strncpy strncpy_is_forbidden_due_to_security_issues_use_av_strlcpy
 #undef  exit
 #define exit exit_is_forbidden
 #ifndef LIBAVFORMAT_BUILD