mirror of
https://gitlab.isc.org/isc-projects/bind9
synced 2025-08-31 06:25:31 +00:00
[master] cleanup strcat/strcpy
4722. [cleanup] Clean up uses of strcpy() and strcat() in favor of strlcpy() and strlcat() for safety. [RT #45981]
This commit is contained in:
@@ -493,7 +493,8 @@ isc_sockaddr_frompath(isc_sockaddr_t *sockaddr, const char *path) {
|
||||
sockaddr->type.sunix.sun_len =
|
||||
(unsigned char)sizeof(sockaddr->type.sunix);
|
||||
#endif
|
||||
strcpy(sockaddr->type.sunix.sun_path, path);
|
||||
strlcpy(sockaddr->type.sunix.sun_path, path,
|
||||
sizeof(sockaddr->type.sunix.sun_path));
|
||||
return (ISC_R_SUCCESS);
|
||||
#else
|
||||
UNUSED(sockaddr);
|
||||
|
Reference in New Issue
Block a user