1
0
mirror of https://github.com/Interlisp/maiko.git synced 2026-03-05 10:44:07 +00:00

Replaces unchecked strcpy with strlcpy.

This commit is contained in:
Nick Briggs
2025-05-19 16:52:49 -07:00
parent 4de8b733fd
commit 987fa637a9

View File

@@ -200,7 +200,7 @@ int main(int argc, char *argv[]) {
goto I_Give_Up;
}
bcopy(if_data.ifc_req[0].ifr_addr.sa_data, ether_host, 6);
strcpy(Ename, if_data.ifc_req[0].ifr_name);
strlcpy(Ename, if_data.ifc_req[0].ifr_name, sizeof(Ename));
fcntl(ether_fd, F_SETFL, fcntl(ether_fd, F_GETFL, 0) | O_ASYNC | O_NONBLOCK);