diff --git a/src/burt_can/burt_can.cpp b/src/burt_can/burt_can.cpp index 020bcb3..0e1f68a 100755 --- a/src/burt_can/burt_can.cpp +++ b/src/burt_can/burt_can.cpp @@ -33,7 +33,7 @@ BurtCanStatus burt_can::BurtCan::open() { } // Define the interface we'll use on the socket - strncpy(ifr.ifr_name, interface, strlen(interface)); + strcpy(ifr.ifr_name, interface); ioctl(handle, SIOCGIFINDEX, &ifr); if (!ifr.ifr_ifindex) { return BurtCanStatus::INTERFACE_PARSE_ERROR;