summaryrefslogtreecommitdiff
path: root/sethdlc.c
diff options
context:
space:
mode:
Diffstat (limited to 'sethdlc.c')
-rw-r--r--sethdlc.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sethdlc.c b/sethdlc.c
index 3514b2e..afbcb20 100644
--- a/sethdlc.c
+++ b/sethdlc.c
@@ -293,7 +293,7 @@ int main(int argc, char *argv[])
if (sock<0)
error("Unable to create socket: %s\n", strerror(errno));
- strcpy(req.ifr_name, argv[1]); /* Device name */
+ strncpy(req.ifr_name, argv[1], sizeof(req.ifr_name) - 1); /* Device name */
if (argc == 2) {
show_port(sock);